Skip to content

Commit

Permalink
fix jar versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
sisby-folk committed Sep 21, 2023
1 parent b1ac8bd commit aecb7f3
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
3 changes: 1 addition & 2 deletions buildSrc/src/main/groovy/switchy.compilation.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ plugins {
}

archivesBaseName = project == rootProject ? project.name : rootProject.name + '-' + project.name
version = "$project.version+$project.branch"

java {
targetCompatibility = sourceCompatibility = JavaVersion.VERSION_17
Expand All @@ -15,8 +16,6 @@ tasks.withType(JavaCompile).configureEach {
}

tasks.withType(Jar).configureEach {
archiveVersion = "${project.version}+${libs.versions.mc.get()}"

from("LICENSE.txt") {
rename { "${it}_${archivesBaseName}" }
}
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/src/main/groovy/switchy.publishing.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ publishing {
mavenJava(MavenPublication) {
from components.java
artifactId "switchy" + '-' + project.name
version "${project.version}+${libs.versions.mc.get()}"
version "$project.version+$project.branch"
}
}

Expand Down
4 changes: 2 additions & 2 deletions buildSrc/src/main/groovy/switchy.releasing.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ tasks.githubRelease {
modrinth {
token = project.findProperty("modrinth.token") ?: System.getenv("MODRINTH_TOKEN")
projectId = 'switchy'
versionNumber = project.version
versionName = "$project.version+${libs.versions.mc.get()}"
versionName = project.version
versionNumber = "$project.version+$project.branch"
versionType = 'release'
uploadFile = remapJar
gameVersions = [libs.versions.mc]
Expand Down
1 change: 1 addition & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ org.gradle.configureondemand=true
fabric.loom.multiProjectOptimisation=true
# Mod Properties
version=2.8.3
branch=1.19
default_release_branch=1.19

0 comments on commit aecb7f3

Please sign in to comment.