Set gradle build version to drone tag or build
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Garrett Mills 2021-02-09 10:53:42 -06:00
parent dcde13993b
commit 23bed9fb7c
Signed by: garrettmills
GPG Key ID: D2BF5FBA8298F246
3 changed files with 11 additions and 1 deletions

View File

@ -5,4 +5,5 @@ steps:
- name: Run the Gradle build
image: glmdev/java-gradle-maven
commands:
- ./prep_workspace.bash
- ./gradlew build shadowJar reobfShadowJar

View File

@ -17,7 +17,7 @@ apply plugin: 'net.minecraftforge.gradle'
apply plugin: 'eclipse'
apply plugin: 'maven-publish'
version = '1.3'
version = '%%CI_BUILD_VERSION%%'
group = 'dev.garrettmills.csx.matterlinkreboot' // http://maven.apache.org/guides/mini/guide-naming-conventions.html
archivesBaseName = 'matterlinkreboot'

9
prep_workspace.bash Executable file
View File

@ -0,0 +1,9 @@
#!/bin/bash -xe
CI_SUB="$DRONE_TAG"
if [ -z "$CI_SUB" ]; then
CI_SUB="ci${DRONE_BUILD_NUMBER}"
fi
sed -i -e "s/%%CI_BUILD_VERSION%%/${CI_SUB}/g" build.gradle