Closed ghost closed 2 years ago
Hi, You should only include the plugin in the root project in a multi project setup and then use the allprojects config to set the version on each sub project.
allprojects {
version = semver.version
}
Could this be the cause of your issue?
Well, if I don't apply plugin inside the allprojects
I can't use semver
extension there:
plugins {
kotlin("jvm") version "1.6.21"
id("com.github.jmongard.git-semver-plugin") version "0.4.2"
}
allprojects {
version = semver.version
repositories { mavenCentral() }
}
gives me
Extension with name 'semver' does not exist. Currently registered extension names: [ext]
Ok, it looks like some there is some problem using kotlin DSL or maybe somthing changed in latest gradle release. This works when I test:
plugins {
id("com.github.jmongard.git-semver-plugin") version "0.4.2"
}
val ver = semver.version;
allprojects {
version = ver
}
I have updated the sample project to latest gradle version (7.4.2), multi project using kotlin dsl: https://github.com/jmongard/Git.SemVersioning.Gradle.Actions-Example
Got it, thanks! Will give it a try!
I got every release is done twice when
Any ideas?
./gradlew releaseVersion
is executed. Configuration is default, plugin version is0.4.2
.