@@ -35,18 +35,24 @@ repositories {
35
35
36
36
dependencies {
37
37
implementation (" org.clojure:clojure:1.12.0" )
38
- implementation (" com.github.ericdallo:clj4intellij:0.7.1 " )
38
+ implementation (" com.github.ericdallo:clj4intellij:0.8.0 " )
39
39
implementation (" seesaw:seesaw:1.5.0" )
40
40
implementation (" camel-snake-kebab:camel-snake-kebab:0.4.3" )
41
41
implementation (" com.rpl:proxy-plus:0.0.9" )
42
42
implementation (" dev.weavejester:cljfmt:0.13.0" )
43
43
implementation (" com.github.clojure-lsp:clojure-lsp:2025.01.22-23.28.23" )
44
+ implementation (" nrepl:nrepl:1.3.1" )
45
+
46
+ testImplementation(" junit:junit:latest.release" )
47
+ testImplementation(" org.junit.platform:junit-platform-launcher:latest.release" )
48
+ testRuntimeOnly (" dev.clojurephant:jovial:0.4.2" )
44
49
}
45
50
46
51
sourceSets {
47
52
main {
48
53
java.srcDirs(" src/main" , " src/gen" )
49
54
if (project.gradle.startParameter.taskNames.contains(" buildPlugin" ) ||
55
+ project.gradle.startParameter.taskNames.contains(" clojureRepl" ) ||
50
56
project.gradle.startParameter.taskNames.contains(" runIde" )) {
51
57
resources.srcDirs(" src/main/dev-resources" )
52
58
}
@@ -146,6 +152,10 @@ tasks {
146
152
systemProperty(" jb.consents.confirmation.enabled" , " false" )
147
153
}
148
154
155
+ test {
156
+ systemProperty(" idea.mimic.jar.url.connection" , " true" )
157
+ }
158
+
149
159
signPlugin {
150
160
certificateChain.set(System .getenv(" CERTIFICATE_CHAIN" ))
151
161
privateKey.set(System .getenv(" PRIVATE_KEY" ))
@@ -165,6 +175,26 @@ tasks {
165
175
enabled = false
166
176
}
167
177
178
+ clojureRepl {
179
+ dependsOn(" compileClojure" )
180
+ classpath.from(sourceSets.main.get().runtimeClasspath
181
+ + file(" build/classes/kotlin/main" )
182
+ + file(" build/clojure/main" )
183
+ )
184
+ // doFirst {
185
+ // println(classpath.asPath)
186
+ // }
187
+ forkOptions.jvmArgs = listOf (" --add-opens=java.desktop/java.awt=ALL-UNNAMED" ,
188
+ " --add-opens=java.desktop/java.awt.event=ALL-UNNAMED" ,
189
+ " --add-opens=java.desktop/sun.awt=ALL-UNNAMED" ,
190
+ " --add-opens=java.desktop/sun.font=ALL-UNNAMED" ,
191
+ " --add-opens=java.base/java.lang=ALL-UNNAMED" ,
192
+ " -Djava.system.class.loader=com.intellij.util.lang.PathClassLoader" ,
193
+ " -Didea.mimic.jar.url.connection=true" ,
194
+ " -Didea.force.use.core.classloader=true"
195
+ )
196
+ }
197
+
168
198
generateParser {
169
199
source.set(" src/main/gramar/clojure.bnf" )
170
200
targetRoot.set(" src/gen" )
@@ -180,14 +210,18 @@ tasks {
180
210
}
181
211
}
182
212
213
+ tasks.withType<Test >().configureEach {
214
+ useJUnitPlatform()
215
+ }
216
+
183
217
grammarKit {
184
218
jflexRelease.set(" 1.7.0-1" )
185
219
grammarKitRelease.set(" 2021.1.2" )
186
220
intellijRelease.set(" 203.7717.81" )
187
221
}
188
222
189
223
clojure.builds.named(" main" ) {
190
- classpath.from(sourceSets.main.get().runtimeClasspath.asPath)
224
+ classpath.from(sourceSets.main.get().runtimeClasspath.asPath + " build/classes/kotlin/main " )
191
225
checkAll()
192
226
aotAll()
193
227
reflection.set(" fail" )
0 commit comments