mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-01-17 04:38:18 +01:00
gradle, set jar version to <version>-<distance>-<sha>
set the version to the last tag, plus the number of commits since the last tag (called "distance"), and the git hash (sha). an example: 1.7.94-9-c9d7deca in case there is an annotated tag on the commit built itself it is a release, and no distance, and sha is added: 1.7.94 in case the build is not from main and master branch, the branch name will be added, special characters are translated to underscore: 1.7.94-9-c9d7deca-other_branch
This commit is contained in:
parent
c9d7deca20
commit
bfa50147ab
@ -1,4 +1,5 @@
|
||||
plugins {
|
||||
id("fr.brouillard.oss.gradle.jgitver") version "0.9.1"
|
||||
id("jacoco")
|
||||
id("java")
|
||||
id("maven-publish")
|
||||
@ -29,9 +30,15 @@ group = "com.rarchives.ripme"
|
||||
version = "1.7.94"
|
||||
description = "ripme"
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
jgitver {
|
||||
gitCommitIDLength = 8
|
||||
nonQualifierBranches = "main,master"
|
||||
useGitCommitID = true
|
||||
}
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
tasks.withType<Jar> {
|
||||
|
Loading…
x
Reference in New Issue
Block a user