mirror of
https://github.com/DiscordSRV/Ascension.git
synced 2024-11-25 12:25:15 +01:00
Don't include the commit hash in the real version
This commit is contained in:
parent
d29d91b97a
commit
e7c82eb386
17
build.gradle
17
build.gradle
@ -17,16 +17,8 @@ subprojects {
|
||||
apply plugin: 'net.kyori.indra.git'
|
||||
apply plugin: 'dev.vankka.dependencydownload.plugin'
|
||||
|
||||
var versionExtra = ""
|
||||
if (rootProject.version.endsWith("-SNAPSHOT") && indraGit.isPresent()) {
|
||||
var gitHash = indraGit.commit().getName()
|
||||
if (gitHash.length() > 7) {
|
||||
gitHash = gitHash.substring(0, 7);
|
||||
}
|
||||
versionExtra = "-" + gitHash
|
||||
}
|
||||
group 'com.discordsrv'
|
||||
version = rootProject.version + versionExtra
|
||||
version = rootProject.version
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
@ -141,6 +133,13 @@ subprojects {
|
||||
)
|
||||
if (indraGit.isPresent()) {
|
||||
indraGit.applyVcsInformationToManifest(manifest)
|
||||
if (rootProject.version.endsWith("-SNAPSHOT")) {
|
||||
var gitHash = indraGit.commit().getName()
|
||||
if (gitHash.length() > 7) {
|
||||
gitHash = gitHash.substring(0, 7);
|
||||
}
|
||||
archiveClassifier = gitHash
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -6,8 +6,8 @@ task copyOutput(type: Copy) {
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
// Don't add -all to the end of the jar name
|
||||
archiveClassifier = ''
|
||||
// Adds the commit for snapshots to the end of the file name
|
||||
archiveClassifier = tasks.jar.archiveClassifier
|
||||
|
||||
// Include the license in the jar
|
||||
from(rootProject.file('LICENSE')) {
|
||||
|
Loading…
Reference in New Issue
Block a user