File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 3232 ORG_GRADLE_PROJECT_mavenCentralPassword : ${{ secrets.OSSRH_TOKEN }}
3333 GPG_SECRET_KEY : ${{ secrets.GPG_SECRET_KEY }}
3434 SIGNING_PASSPHRASE : ${{ secrets.SIGNING_PASSPHRASE }}
35- GITHUB_RUN_NUMBER : ' -1 ' # this means that a base version won't have a suffix i.e., the version will be `0.1`
35+ RELEASE_PUBLICATION : ' true '
Original file line number Diff line number Diff line change @@ -5,14 +5,15 @@ plugins {
55}
66
77private val buildNumber: String? = System .getenv(" GITHUB_RUN_NUMBER" )
8+ private val isReleasePublication = System .getenv(" RELEASE_PUBLICATION" )?.toBoolean() ? : false
89
9- private val baseVersion = " 0.1"
10+ private val baseVersion = " 0.1.0 "
1011
1112allprojects {
1213 group = " com.agentclientprotocol"
13- version = when (buildNumber) {
14- " -1 " -> baseVersion // -1 as a buildNumber means that we are releasing this version
15- null -> " $baseVersion -SNAPSHOT"
16- else -> " $baseVersion -dev$buildNumber "
14+ version = when {
15+ isReleasePublication -> baseVersion
16+ buildNumber == null -> " $baseVersion -SNAPSHOT"
17+ else -> " $baseVersion -dev- $buildNumber "
1718 }
1819}
You can’t perform that action at this time.
0 commit comments