Skip to content

Commit cdeb027

Browse files
committed
build: use JetBrains JDK and enable DCEVM by default
1 parent c0db63d commit cdeb027

6 files changed

Lines changed: 45 additions & 14 deletions

File tree

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,3 +139,8 @@ Desktop.ini
139139
# Maven Wrapper
140140
######################
141141
!.mvn/wrapper/maven-wrapper.jar
142+
143+
######################
144+
# Plugin Development
145+
######################
146+
!hotswap-agent-2.0.1.jar

.run/Run Plugin.run.xml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<component name="ProjectRunConfigurationManager">
2+
<configuration default="false" name="Run Plugin" type="GradleRunConfiguration" factoryName="Gradle">
3+
<ExternalSystemSettings>
4+
<option name="executionName" />
5+
<option name="externalProjectPath" value="$PROJECT_DIR$" />
6+
<option name="externalSystemIdString" value="GRADLE" />
7+
<option name="scriptParameters" value="" />
8+
<option name="taskDescriptions">
9+
<list />
10+
</option>
11+
<option name="taskNames">
12+
<list>
13+
<option value=":runIde" />
14+
</list>
15+
</option>
16+
<option name="vmOptions" value=" " />
17+
</ExternalSystemSettings>
18+
<ExternalSystemDebugServerProcess>false</ExternalSystemDebugServerProcess>
19+
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
20+
<ExternalSystemDebugDisabled>false</ExternalSystemDebugDisabled>
21+
<DebugAllEnabled>false</DebugAllEnabled>
22+
<RunAsTest>false</RunAsTest>
23+
<GradleProfilingDisabled>false</GradleProfilingDisabled>
24+
<GradleCoverageDisabled>false</GradleCoverageDisabled>
25+
<method v="2" />
26+
</configuration>
27+
</component>

build.gradle.kts

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import org.jetbrains.grammarkit.tasks.GenerateLexerTask
22
import org.jetbrains.intellij.platform.gradle.IntelliJPlatformType
33
import org.jetbrains.intellij.platform.gradle.TestFrameworkType
44
import org.jetbrains.intellij.platform.gradle.extensions.intellijPlatform
5+
import org.jetbrains.intellij.platform.gradle.utils.asPath
56
import org.jetbrains.kotlin.gradle.dsl.JvmDefaultMode
67
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
78
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
@@ -91,12 +92,13 @@ sourceSets {
9192
}
9293
}
9394

94-
java {
95-
sourceCompatibility = JavaVersion.VERSION_21
96-
targetCompatibility = JavaVersion.VERSION_21
97-
}
98-
9995
kotlin {
96+
@Suppress("UnstableApiUsage")
97+
jvmToolchain {
98+
languageVersion = JavaLanguageVersion.of(21)
99+
vendor = JvmVendorSpec.JETBRAINS
100+
}
101+
100102
explicitApiWarning()
101103
compilerOptions {
102104
languageVersion = KotlinVersion.KOTLIN_2_3
@@ -142,11 +144,7 @@ tasks {
142144
}
143145

144146
runIde {
145-
val dcevm = stringProperty("dcevmExecutable", default = "")
146-
147-
if (dcevm.isNotBlank()) {
148-
@Suppress("UsePropertyAccessSyntax")
149-
setExecutable(dcevm)
150-
}
147+
val agentPath = layout.projectDirectory.file("hotswap-agent-2.0.1.jar").asPath
148+
jvmArgs("-XX:+AllowEnhancedClassRedefinition", "-XX:HotswapAgent=external", "-javaagent:$agentPath")
151149
}
152150
}

gradle.properties

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,3 @@ pluginSinceBuild = 253.17525
1818
# Optionally, also add a matching What's New page in
1919
# com.github.lppedd.cc.whatsnew.InternalWhatsNewProvider.whatsNewPages
2020
version = 0.26.0
21-
22-
# (Optional) Absolute path to a DCEVM-enabled VM, eg. '.../bin/java.exe'
23-
dcevmExecutable =

hotswap-agent-2.0.1.jar

1.87 MB
Binary file not shown.

settings.gradle.kts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,8 @@ pluginManagement {
44
}
55
}
66

7+
plugins {
8+
id("org.gradle.toolchains.foojay-resolver-convention") version "1.0.0"
9+
}
10+
711
rootProject.name = "idea-conventional-commit"

0 commit comments

Comments
 (0)