@@ -8,7 +8,17 @@ plugins {
88}
99
1010group = " io.github.thisisthepy"
11- version = " 3.13.0" // kept in step with the root build's version, which the processor is published under
11+ // Same published version as the library and the KSP processor (#70): "$pythonVersion-$suffix" from
12+ // the root's gradle.properties, a -P override winning as it does in the root build (Gradle hands
13+ // start-parameter properties to included builds too).
14+ val rootGradleProperties = Properties ().apply {
15+ val file = rootDir.resolve(" ../gradle.properties" )
16+ if (file.isFile) file.inputStream().use { load(it) }
17+ }
18+ fun rootProperty (name : String , fallback : String ): String =
19+ findProperty(name)?.toString() ? : rootGradleProperties.getProperty(name) ? : fallback
20+ val publishedVersion = " ${rootProperty(" pythonVersion" , " 3.15.0" )} -${rootProperty(" libraryVersionSuffix" , " alpha01" )} "
21+ version = publishedVersion
1222
1323/* *
1424 * `KlibScanner`'s reader, named once because three places have to agree on it: this module's own
@@ -239,20 +249,13 @@ val generateCoordinates = tasks.register("generateCoordinates") {
239249 // second copy of these values that drifted would pair a stdlib with an interpreter from a
240250 // different build. The fallbacks match `python-multiplatform/build.gradle.kts`'s own, for the
241251 // case where this build is checked out without the root's properties beside it.
242- val rootProperties = Properties ().apply {
243- val file = rootDir.resolve(" ../gradle.properties" )
244- if (file.isFile) file.inputStream().use { load(it) }
245- }
246- val pythonVersionValue = rootProperties.getProperty(" pythonVersion" ) ? : " 3.15.0"
247- val pbsReleaseValue = rootProperties.getProperty(" pythonBuildStandaloneRelease" ) ? : " 20261013"
248- val freeThreadedValue = rootProperties.getProperty(" pythonFreeThreaded" )?.toBoolean() ? : false
252+ val pythonVersionValue = rootProperty(" pythonVersion" , " 3.15.0" )
253+ val pbsReleaseValue = rootProperty(" pythonBuildStandaloneRelease" , " 20261013" )
254+ val freeThreadedValue = rootProperty(" pythonFreeThreaded" , " false" ).toBoolean()
249255
250- // `python-multiplatform` itself is versioned "$pythonVersion-alpha01" -- see that build's own
251- // `val libraryVersion` -- which is *not* this plugin build's `project.version` (kept in step by
252- // hand, see the top of this file). The wasm-runtime zip is published under the library's
253- // version, alongside the library artifact it has to pair with, so the coordinate has to be
254- // built the same way rather than reusing this plugin's own version.
255- val libraryVersionValue = " $pythonVersionValue -alpha01"
256+ // The library and this plugin publish under one version since #70, so the wasm-runtime zip
257+ // (published beside the library artifact) is at this build's own version.
258+ val libraryVersionValue = publishedVersion
256259 val wasmRuntimeCoordinatesValue = " ${project.group} :python-multiplatform-wasm-runtime:$libraryVersionValue "
257260
258261 val klibWorkerValue = klibWorkerCoordinates
0 commit comments