Change from tag-based versioning to commit/file based

This commit is contained in:
Jonas Herzig
2018-03-03 11:27:51 +01:00
parent 9c76f0fcc0
commit 78ad02bc84
3 changed files with 60 additions and 43 deletions

View File

@@ -24,9 +24,7 @@ sourceCompatibility = 1.8
targetCompatibility = 1.8
afterEvaluate {
def gitVer = gitDescribe()
if (gitVer.startsWith('1.12.2-')) gitVer = gitVer.substring('1.12.2-'.length()) // until the first proper version
version = project.minecraft.version + '-' + gitVer
version = project.minecraft.version + '-' + rootProject.version
}
group= "com.replaymod"
archivesBaseName = "replaymod"
@@ -204,19 +202,6 @@ jar {
}
}
def gitDescribe() {
try {
def stdout = new ByteArrayOutputStream()
exec {
commandLine 'git', 'describe', '--always', '--dirty=*'
standardOutput = stdout
}
return stdout.toString().trim()
} catch (e) {
return "unknown"
}
}
processResources
{
// this will ensure that this task is redone when the versions change.