Skip to content

Commit

Permalink
More version suffix fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ejsmith committed Aug 25, 2024
1 parent 1745e49 commit 11b6d11
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/build-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,24 +41,21 @@ jobs:
- name: Build Reason
run: |
branch=${GITHUB_REF##*/}.
if [ "$branch" = "main." ]; then
if [[ "$branch" = "main." ]]; then
branch=""
fi
if [ "$branch" = "master." ]; then
elif [[ "$branch" = "master." ]]; then
branch=""
fi
if [ "${GITHUB_REF%%/*}" = "refs/tags" ]; then
elif [[ "${GITHUB_REF}" = refs/tags* ]]; then
branch=""
fi
if [ "${GITHUB_REF%%/*}" = "refs/pull" ]; then
elif [[ "${GITHUB_REF}" = refs/pull* ]]; then
branch=""
fi
echo "GIT_BRANCH_SUFFIX=$branch" >> $GITHUB_ENV
echo branch: $branch ref: $GITHUB_REF event: $GITHUB_EVENT_NAME
- name: Build Version
run: |
dotnet tool install --global minver-cli --version 5.0.0
version=$(minver --tag-prefix v --default-pre-release-identifiers alpha.${GIT_BRANCH_SUFFIX}.0)
version=$(minver --tag-prefix v --default-pre-release-identifiers alpha.${GIT_BRANCH_SUFFIX}0)
echo "MINVERVERSIONOVERRIDE=$version" >> $GITHUB_ENV
echo "### Version: $version" >> $GITHUB_STEP_SUMMARY
- name: Build
Expand Down

0 comments on commit 11b6d11

Please sign in to comment.