Set the final version with tag name when releasing (#1511)

Signed-off-by: John Niang <johnniang@fastmail.com>
pull/1515/head
John Niang 2021-11-01 23:16:41 +08:00 committed by GitHub
parent 4ffbd502fe
commit a376dca4d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 4 deletions

View File

@ -47,8 +47,10 @@ jobs:
cache: 'gradle'
java-version: 11
- name: Build with Gradle
run: ./gradlew clean build -x test
run: |
# Set the version with tag name when releasing
sed -i "s/version=.*-SNAPSHOT$/version=${{ github.event.release.tag_name }}/1" gradle.properties
./gradlew clean build -x test
- name: Archive halo jar
uses: actions/upload-artifact@v2
with:

View File

@ -6,7 +6,6 @@ plugins {
}
group = "run.halo.app"
version = "1.4.13"
description = "Halo, An excellent open source blog publishing application."
sourceCompatibility = JavaVersion.VERSION_11

1
gradle.properties Normal file
View File

@ -0,0 +1 @@
version=1.4.13-SNAPSHOT