Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
plugins {
alias(libs.plugins.kotlin.multiplatform) apply false
// 0.3.4-ONLY WORKAROUND (#194) — DELETE THIS LINE with the pluginManagement bump to 0.3.5.
// Declared here (never applied) purely to put the kplusplus plugin on the ROOT buildscript
// classpath next to the Kotlin plugin, so both resolve as ONE classpath. 0.3.4's plugin
// carried its ksrpc/ktor/coroutines runtime as ordinary dependencies, which a multi-project
// consumer resolves into a CHILD classloader while parent-first loading keeps serving the
// ROOT's older kotlinx-coroutines — `NoSuchMethodError: Job.invokeOnCompletion$default`
// before krapper is even started. 0.3.5 SHADES that runtime into the plugin jar (see
// compiler/gradle/build.gradle.kts), which is the actual fix; this line is only what keeps
// THIS repo building while it self-hosts one release behind, on 0.3.4.
id("com.monkopedia.kplusplus.compiler") apply false
alias(libs.plugins.ktlint)
}

Expand Down
12 changes: 6 additions & 6 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ pluginManagement {
```kotlin
plugins {
kotlin("multiplatform") version "2.4.0"
id("com.monkopedia.kplusplus.compiler") version "0.3.4"
id("com.monkopedia.kplusplus.compiler") version "0.3.5"
}

repositories {
Expand All @@ -47,13 +47,13 @@ repositories {
```

In a **multi-project** build, apply this in whichever project owns the bindings; the plugin
does not need to be declared at the root alongside the Kotlin plugin. (Under **0.3.4 only** it
did — the plugin's own runtime classes were shadowed by whatever the root buildscript
does not need to be declared at the root alongside the Kotlin plugin. (It did under **0.3.4
only** — the plugin's own runtime classes were shadowed by whatever the root buildscript
classloader owned, and the first `kplusplusSync` failed with
`NoSuchMethodError: Job.invokeOnCompletion$default`. Adding
`NoSuchMethodError: Job.invokeOnCompletion$default`. 0.3.5 shades that runtime into the plugin
jar, which is the real fix; if you are stuck on 0.3.4, adding
`id("com.monkopedia.kplusplus.compiler") apply false` to the root `plugins { }` block works
around it on 0.3.4; upgrading is the real fix. See
[#194](https://github.com/Monkopedia/kplusplus/issues/194).)
around it. See [#194](https://github.com/Monkopedia/kplusplus/issues/194).)

## 2. Configure the binding

Expand Down
2 changes: 1 addition & 1 deletion samples/minimal/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ plugins {
// The kplusplus compiler subplugin, resolved from its published mavenLocal marker
// (R2, #128) — no includeBuild. Everything kplusplus-specific lives in the narrow
// `kplusplus { ... }` block at the bottom of this file.
id("com.monkopedia.kplusplus.compiler") version "0.3.4"
id("com.monkopedia.kplusplus.compiler") version "0.3.5"
id("com.monkopedia.klinker.plugin") version "0.2.0"
}

Expand Down
8 changes: 4 additions & 4 deletions samples/multiproject/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ That is the entire test. What it binds does not matter.

## Run it

The plugin is resolved by coordinate (`mavenLocal()` first), so publish the build under test
The plugin is resolved by coordinate, `mavenLocal()` first. With an empty `mavenLocal` the pin
resolves the last **released** plugin, which is a useful post-release check that #194 is still
fixed in what actually shipped. To exercise the build *under test* instead, publish it locally
first — the release local dry run, from the repo root:

```sh
Expand All @@ -49,6 +51,4 @@ service channel to krapper, before any binding is generated. Compiling the gener
(`../../gradlew :bindings:build`) exercises the rest, but is not what this sample is for.

`:bindings:build` is step 4 of the release **local dry run** ([docs/releasing.md](../../docs/releasing.md)),
which is where this sample is exercised. It has no CI workflow of its own — unlike
`samples/minimal` it cannot run against the *released* plugin, since the plugin under test is
the point.
which is where this sample is exercised. It has no CI workflow of its own.
2 changes: 1 addition & 1 deletion samples/multiproject/bindings/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
// this is a from-published consumer.
plugins {
kotlin("multiplatform")
id("com.monkopedia.kplusplus.compiler") version "0.3.4"
id("com.monkopedia.kplusplus.compiler") version "0.3.5"
}

repositories {
Expand Down
2 changes: 1 addition & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ pluginManagement {
// PLUGIN development happens in an example (samples/*) that includeBuilds compiler. Bump
// this version on each release.
plugins {
id("com.monkopedia.kplusplus.compiler") version "0.3.4"
id("com.monkopedia.kplusplus.compiler") version "0.3.5"
}
}

Expand Down
Loading