Skip to content

Commit

Permalink
fix typo
Browse files Browse the repository at this point in the history
Signed-off-by: hlts2 <hiroto.funakoshi.hiroto@gmail.com>
  • Loading branch information
hlts2 committed Sep 20, 2023
1 parent 972b72b commit d099a08
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
semver-auto:
runs-on: ubuntu-latest
outputs:
RELEASE_BRANCH_NAME_PREFIX: ${{ steps.set_context.outputs.RELEASE_BRANCH_NAME_PREFIX }}
RELEASE_BRANCH_NAME_SUFFIX: ${{ steps.set_context.outputs.RELEASE_BRANCH_NAME_SUFFIX }}
RELEASE_TAG: ${{ steps.upgrade_semver.outputs.RELEASE_TAG }}
RELEASE: ${{ steps.upgrade_semver.outputs.RELEASE }}
steps:
Expand All @@ -45,29 +45,29 @@ jobs:
- name: Set Github context
id: set_context
run: |
RELEASE_BRANCH_NAME_PREFIX=`echo '${{ github.ref }}' | sed -e 's:^refs/heads/release/::'`
BRANCH_LATEST_TAG=`git tag | grep ${RELEASE_BRANCH_NAME_PREFIX} | tail -n 1`
RELEASE_BRANCH_NAME_SUFFIX=`echo '${{ github.ref }}' | sed -e 's:^refs/heads/release/::'`
BRANCH_LATEST_TAG=`git tag | grep ${RELEASE_BRANCH_NAME_SUFFIX} | tail -n 1`
RELEASE_KIND=`echo "${{ github.event.head_commit.message }}" | sed -n -E 's:^\[(major|minor|patch)\].*:\1:p'`
echo "RELEASE_BRANCH_NAME_PREFIX=${RELEASE_BRANCH_NAME_PREFIX}" >> $GITHUB_OUTPUT # e.g) vx.x
echo "RELEASE_BRANCH_NAME_SUFFIX=${RELEASE_BRANCH_NAME_SUFFIX}" >> $GITHUB_OUTPUT # e.g) vx.x
echo "BRANCH_LATEST_TAG=${BRANCH_LATEST_TAG}" >> $GITHUB_OUTPUT # e.g) vx.x.x or empty
echo "RELEASE_KIND=${RELEASE_KIND}" >> $GITHUB_OUTPUT # e.g) major or minor or patch or empty
echo "${RELEASE_BRANCH_NAME_PREFIX}"
echo "${RELEASE_BRANCH_NAME_SUFFIX}"
echo "${BRANCH_LATEST_TAG}"
echo "${RELEASE_KIND}"
- name: Upgrade semver
id: upgrade_semver
if: ${{ steps.set_context.outputs.RELEASE_KIND != '' }}
env:
RELEASE_BRANCH_NAME_PREFIX: ${{ steps.set_context.outputs.RELEASE_BRANCH_NAME_PREFIX }}
RELEASE_BRANCH_NAME_SUFFIX: ${{ steps.set_context.outputs.RELEASE_BRANCH_NAME_SUFFIX }}
BRANCH_LATEST_TAG: ${{ steps.set_context.outputs.BRANCH_LATEST_TAG }}
RELEASE_KIND: ${{ steps.set_context.outputs.RELEASE_KIND }}
run: |
if [ -z "${BRANCH_LATEST_TAG}" ]; then
case ${RELEASE_KIND} in
major | minor) RELEASE_TAG="${RELEASE_BRANCH_NAME_PREFIX}.0"; ;;
major | minor) RELEASE_TAG="${RELEASE_BRANCH_NAME_SUFFIX}.0"; ;;
*) echo "not supported semver kind"; exit 1; ;;
esac
else
Expand Down Expand Up @@ -98,7 +98,7 @@ jobs:
container:
image: ghcr.io/vdaas/vald/vald-ci-container:${{ needs.detect-ci-container.outputs.TAG_NAME }}
env:
RELEASE_BRANCH_NAME: release/${{ needs.semver-auto.outputs.RELEASE_BRANCH_NAME_PREFIX }}
RELEASE_BRANCH_NAME: release/${{ needs.semver-auto.outputs.RELEASE_BRANCH_NAME_SUFFIX }}
RELEASE_TAG: ${{ needs.semver-auto.outputs.RELEASE_TAG }}
steps:
- uses: actions/checkout@v3
Expand Down

0 comments on commit d099a08

Please sign in to comment.