Skip to content

Commit f076d72

Browse files
Switch to a different Kotlin library for snapshots
I've had some issues indexing libraries that depend on android, so we choose one that doesn't.
1 parent c46bacf commit f076d72

File tree

173 files changed

+68666
-36880
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

173 files changed

+68666
-36880
lines changed

build.sbt

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ lazy val V =
2828
val requests = "0.8.0"
2929
val minimalMillVersion = "0.10.0"
3030
val millScipVersion = "0.3.6"
31-
val kotlinVersion = "1.9.22"
31+
val kotlinVersion = "2.1.20"
3232
}
3333

3434
inThisBuild(
@@ -286,7 +286,13 @@ lazy val cli = project
286286
"com.lihaoyi" %% "requests" % V.requests,
287287
"org.scalameta" %% "moped" % V.moped,
288288
"org.scalameta" %% "ascii-graphs" % "0.1.2",
289-
"org.jetbrains.kotlin" % "kotlin-compiler-embeddable" % V.kotlinVersion
289+
"org.jetbrains.kotlin" % "kotlin-compiler-embeddable" % V.kotlinVersion,
290+
"org.jetbrains.kotlin" % "kotlin-scripting-common" % V.kotlinVersion,
291+
"org.jetbrains.kotlin" % "kotlin-scripting-jvm" % V.kotlinVersion,
292+
"org.jetbrains.kotlin" % "kotlin-scripting-dependencies" %
293+
V.kotlinVersion,
294+
"org.jetbrains.kotlin" % "kotlin-scripting-dependencies-maven" %
295+
V.kotlinVersion
290296
),
291297
(Compile / resourceGenerators) +=
292298
Def

scip-java/src/main/scala/com/sourcegraph/scip_java/buildtools/ScipBuildTool.scala

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -235,22 +235,23 @@ class ScipBuildTool(index: IndexCommand) extends BuildTool("SCIP", index) {
235235
config: Config,
236236
allKotlinFiles: List[Path]
237237
): Try[Unit] = {
238+
println(allKotlinFiles)
238239
if (allKotlinFiles.isEmpty || config.dependencies.isEmpty)
239240
return Success()
240241
val filesPaths = allKotlinFiles.map(_.toString)
241242

243+
val kotlinPluginVersion = BuildInfo.semanticdbKotlincVersion
242244
val plugin =
243245
Dependencies
244246
.resolveDependencies(
245-
List(
246-
s"com.sourcegraph:semanticdb-kotlinc:${BuildInfo
247-
.semanticdbKotlincVersion}"
248-
),
247+
List(s"com.sourcegraph:semanticdb-kotlinc:$kotlinPluginVersion"),
249248
transitive = false
250249
)
251250
.classpath
252251
.head
253252

253+
println(plugin)
254+
254255
val self = config.dependencies.head
255256
val commonKotlinFiles: List[Path] =
256257
Dependencies.kotlinMPPCommon(
@@ -302,11 +303,12 @@ class ScipBuildTool(index: IndexCommand) extends BuildTool("SCIP", index) {
302303
"-no-stdlib",
303304
"-Xmulti-platform",
304305
"-Xno-check-actual",
305-
"-Xopt-in=kotlin.RequiresOptIn",
306-
"-Xopt-in=kotlin.ExperimentalUnsignedTypes",
307-
"-Xopt-in=kotlin.ExperimentalStdlibApi",
308-
"-Xopt-in=kotlin.ExperimentalMultiplatform",
309-
"-Xopt-in=kotlin.contracts.ExperimentalContracts",
306+
"-verbose:class",
307+
"-opt-in=kotlin.RequiresOptIn",
308+
"-opt-in=kotlin.ExperimentalUnsignedTypes",
309+
"-opt-in=kotlin.ExperimentalStdlibApi",
310+
"-opt-in=kotlin.ExperimentalMultiplatform",
311+
"-opt-in=kotlin.contracts.ExperimentalContracts",
310312
"-Xallow-kotlin-package",
311313
s"-Xplugin=$plugin",
312314
"-P",
@@ -318,10 +320,10 @@ class ScipBuildTool(index: IndexCommand) extends BuildTool("SCIP", index) {
318320
)
319321

320322
if (commonKotlinFiles.nonEmpty) {
321-
args +=
322-
s"-Xcommon-sources=${commonKotlinFiles
323-
.map(_.toAbsolutePath.toString)
324-
.mkString(",")}"
323+
val commonSources = commonKotlinFiles
324+
.map(_.toAbsolutePath.toString)
325+
.mkString(",")
326+
args += s"-Xcommon-sources=$commonSources"
325327
}
326328

327329
args ++= filesPaths ++ commonKotlinFiles.map(_.toAbsolutePath.toString)

tests/snapshots/src/main/generated/com/airbnb/epoxy/ActivityRecyclerPool.kt

Lines changed: 0 additions & 307 deletions
This file was deleted.

tests/snapshots/src/main/generated/com/airbnb/epoxy/AsyncEpoxyController.java

Lines changed: 0 additions & 109 deletions
This file was deleted.

0 commit comments

Comments
 (0)