Skip to content

Commit

Permalink
action: fix release tag
Browse files Browse the repository at this point in the history
  • Loading branch information
stevejohnson7 committed Nov 3, 2023
1 parent dc80d75 commit a08a0c1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/build-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ jobs:
id: process-version
run: |
VERSION_TAG=${{ inputs.release-tag }}
VERSION_TAG=${VERSION_TAG#v} # remove the 'v' prefix
VERSION_TAG=${VERSION_TAG#v} # remove the 'v' prefix
IFS='.' read -ra VERSION_PARTS <<< "$VERSION_TAG" # split into array
VERSION_CODE=$(printf "%1d%02d%03d" "${VERSION_PARTS[0]}" "${VERSION_PARTS[1]}" "${VERSION_PARTS[2]}")
echo "versonName=${{ inputs.release-tag }}" >> $GITHUB_OUTPUT
echo "versonCode=$VERSION_CODE" >> $GITHUB_OUTPUT
echo "versonName=$VERSION_TAG" >> $GITHUB_OUTPUT # "1.2.3"
echo "versonCode=$VERSION_CODE" >> $GITHUB_OUTPUT # "102003"
# Re-write version in build.gradle.kts
- name: Re-write version
Expand Down Expand Up @@ -97,15 +97,15 @@ jobs:
- name: Tag Repo
uses: richardsimko/update-tag@v1
with:
tag_name: ${{ steps.process-version.outputs.versonName }}
tag_name: ${{ inputs.release-tag }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Upload Release
uses: softprops/action-gh-release@v1
if: ${{ success() }}
with:
tag_name: ${{ steps.process-version.outputs.versonName }}
tag_name: ${{ inputs.release-tag }}
files: app/build/outputs/apk/meta/release/*
generate_release_notes: true

Expand Down

0 comments on commit a08a0c1

Please sign in to comment.