-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
97 lines (92 loc) · 2.27 KB
/
Copy pathbuild.gradle.kts
File metadata and controls
97 lines (92 loc) · 2.27 KB
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
plugins {
id("java")
id("org.jetbrains.kotlin.jvm") version "1.9.22"
id("org.jetbrains.intellij.platform") version "2.10.5"
}
val pluginVersion = "1.3.0"
group = "de.bungee.idea.plugins.uifile"
version = pluginVersion
// Configure Java compatibility for JDK 21 (required by IntelliJ Platform 2025.1+)
java {
sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
toolchain {
languageVersion.set(JavaLanguageVersion.of(21))
}
}
kotlin {
jvmToolchain(21)
}
// Optimize Java compilation
tasks.withType<JavaCompile> {
options.apply {
encoding = "UTF-8"
// Enable all compiler optimizations
compilerArgs.addAll(
listOf(
"-Xlint:all",
"-Xlint:-serial",
"-parameters"
)
)
// Enable incremental compilation
isIncremental = true
}
}
repositories {
mavenCentral()
intellijPlatform {
defaultRepositories()
}
}
// Exclude Kotlin stdlib to avoid conflicts with IntelliJ Platform's bundled version
configurations.all {
exclude(
group = "org.jetbrains.kotlin",
module = "kotlin-stdlib"
)
exclude(
group = "org.jetbrains.kotlin",
module = "kotlin-stdlib-common"
)
exclude(
group = "org.jetbrains.kotlin",
module = "kotlin-stdlib-jdk8"
)
exclude(
group = "org.jetbrains.kotlin",
module = "kotlin-stdlib-jdk7"
)
}
dependencies {
intellijPlatform {
intellijIdeaCommunity("2025.1")
bundledPlugins(listOf(/* Plugin Dependencies */))
}
testImplementation("junit:junit:4.13.2")
}
// Configure Gradle IntelliJ Platform Plugin
intellijPlatform {
buildSearchableOptions = false
pluginConfiguration {
version = pluginVersion
ideaVersion {
sinceBuild = "251"
untilBuild = "253.*"
}
}
pluginVerification {
ides {
recommended()
}
}
signing {
certificateChain =
System.getenv("CERTIFICATE_CHAIN")
privateKey = System.getenv("PRIVATE_KEY")
password = System.getenv("PRIVATE_KEY_PASSWORD")
}
publishing {
token = System.getenv("PUBLISH_TOKEN")
}
}