mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-08-07 22:37:40 +02: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:
@@ -1,4 +1,5 @@
|
|||||||
plugins {
|
plugins {
|
||||||
|
id("fr.brouillard.oss.gradle.jgitver") version "0.9.1"
|
||||||
id("jacoco")
|
id("jacoco")
|
||||||
id("java")
|
id("java")
|
||||||
id("maven-publish")
|
id("maven-publish")
|
||||||
@@ -29,6 +30,12 @@ group = "com.rarchives.ripme"
|
|||||||
version = "1.7.94"
|
version = "1.7.94"
|
||||||
description = "ripme"
|
description = "ripme"
|
||||||
|
|
||||||
|
jgitver {
|
||||||
|
gitCommitIDLength = 8
|
||||||
|
nonQualifierBranches = "main,master"
|
||||||
|
useGitCommitID = true
|
||||||
|
}
|
||||||
|
|
||||||
java {
|
java {
|
||||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||||
targetCompatibility = JavaVersion.VERSION_1_8
|
targetCompatibility = JavaVersion.VERSION_1_8
|
||||||
|
Reference in New Issue
Block a user