-
Notifications
You must be signed in to change notification settings - Fork 46
/
build.gradle.kts
69 lines (57 loc) · 1.71 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
fun properties(key: String) = project.findProperty(key).toString()
plugins {
id("java")
id("org.jetbrains.kotlin.jvm") version "1.6.21"
id("org.jetbrains.intellij") version "1.5.3"
}
apply(plugin = "org.jetbrains.intellij")
apply(plugin = "java")
apply(plugin = "idea")
group = "com.herbert.george.flutter-snippets"
var versionString: String = "${properties("version")}-${properties("releaseChannel")}-${properties("iteration")}"
version = versionString
repositories {
mavenCentral()
}
dependencies {
testImplementation("junit:junit:4.12")
}
tasks {
// Set the JVM compatibility versions
properties("javaVersion").let {
withType<JavaCompile> {
sourceCompatibility = it
targetCompatibility = it
}
withType<KotlinCompile> {
kotlinOptions.jvmTarget = it
}
}
patchPluginXml {
version.set(versionString)
changeNotes.set("Upgrade project to run use Kotlin and the latest IntelliJ plugins and IDEs")
sinceBuild.set(properties("pluginSinceBuild"))
}
publishPlugin {
channels.set(listOf(properties("releaseChannel")))
token.set(properties("intellijToken"))
}
runPluginVerifier {
ideVersions.set(
listOf(
"IC-221.5591.52",
"IC-222.2270.31"
)
)
verifierVersion.set("latest")
}
}
intellij {
plugins.set(
listOf("java", "Dart:${properties("dartVersion")}", "io.flutter:${properties("flutterVersion")}")
)
version.set(properties("ideaVersion"))
type.set(properties("ideaType"))
pluginName.set(properties("pluginName"))
}