Skip to content

Commit

Permalink
fix(actions): update create-tag action (#1360)
Browse files Browse the repository at this point in the history
  • Loading branch information
vascoalramos authored and aquemy committed Jun 20, 2023
1 parent a62e520 commit deee44e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 deletions.
14 changes: 5 additions & 9 deletions .github/workflows/merge-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,15 @@ jobs:

- name: Extract semantic version
id: semantic
run: echo ::set-output name=value::$(echo ${{ steps.latest_tag.outputs.tag }} | sed -r 's|([0-9]+.[0-9]+.[0-9]+).*|\1|g')

- name: Computed Semantic Version
run: echo ${{ steps.semantic.outputs.value }}
run: echo "value=$(echo ${{ steps.latest_tag.outputs.tag }} | sed -r 's|([0-9]+.[0-9]+.[0-9]+).*|\1|g')" >> $GITHUB_OUTPUT

- name: Count number or releases for tag
id: build_number
run: echo "::set-output name=value::$(($(git tag | grep -c ${{ steps.semantic.outputs.value }}.pre) + 1))"
run: echo "value=$(($(git tag | grep -c ${{ steps.semantic.outputs.value }}.pre) + 1))" >> $GITHUB_OUTPUT

- name: Compute version
id: version
run: echo "::set-output name=value::${{ steps.semantic.outputs.value }}.pre${{ steps.build_number.outputs.value }}"
run: echo "value=${{ steps.semantic.outputs.value }}.pre${{ steps.build_number.outputs.value }}" >> $GITHUB_OUTPUT


prerelease-tag:
Expand All @@ -52,9 +49,8 @@ jobs:
- prepare

steps:
- uses: simpleactions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
- uses: ydataai/[email protected]
with:
tag: ${{ needs.prepare.outputs.version }}
message: ${{ github.event.head_commit.message }}
github_token: ${{ secrets.ACCESS_TOKEN }}
4 changes: 2 additions & 2 deletions .github/workflows/merge-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ jobs:

- name: Count number or releases for tag
id: build_number
run: echo "::set-output name=value::$(($(git tag | grep -c ${{ steps.semantic.outputs.new_release_version }}.rc) + 1))"
run: echo "value=$(($(git tag | grep -c ${{ steps.semantic.outputs.new_release_version }}.rc) + 1))" >> $GITHUB_OUTPUT

- name: Compute version
id: version
run: echo "::set-output name=value::${{ steps.semantic.outputs.new_release_version }}.rc${{ steps.build_number.outputs.value }}"
run: echo "value=${{ steps.semantic.outputs.new_release_version }}.rc${{ steps.build_number.outputs.value }}" >> $GITHUB_OUTPUT


docs-changelog:
Expand Down

0 comments on commit deee44e

Please sign in to comment.