Skip to content

Commit c64f545

Browse files
Fix autorelease-tag workflow version bumps (#398)
1 parent 430afb8 commit c64f545

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

.github/workflows/autorelease-tag.yml

+12-4
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
workflow_dispatch:
99

1010
jobs:
11-
tag:
11+
bump-version:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- uses: actions/checkout@v3
@@ -19,13 +19,13 @@ jobs:
1919
uses: actions/setup-go@v4
2020
with:
2121
go-version: 1.21.x
22-
22+
2323
- name: Bump version in banner.go
2424
working-directory: internal/runner
2525
run: |
2626
curl -LO https://raw.githubusercontent.com/projectdiscovery/utils/main/scripts/versionbump/versionbump.go
2727
go run versionbump.go -file banner.go -var version -part patch
28-
28+
2929
- name: Create local changes
3030
working-directory: internal/runner
3131
run: |
@@ -44,6 +44,14 @@ jobs:
4444
github_token: ${{ secrets.GITHUB_TOKEN }}
4545
branch: ${{ github.ref }}
4646

47+
tag-release:
48+
runs-on: ubuntu-latest
49+
needs: bump-version
50+
steps:
51+
- uses: actions/checkout@v3
52+
with:
53+
fetch-depth: 0
54+
4755
- name: Get Commit Count
4856
id: get_commit
4957
run: git rev-list `git rev-list --tags --no-walk --max-count=1`..HEAD --count | xargs -I {} echo COMMIT_COUNT={} >> $GITHUB_OUTPUT
@@ -54,7 +62,7 @@ jobs:
5462
uses: mathieudutour/[email protected]
5563
with:
5664
github_token: ${{ secrets.PDTEAMX_PAT }}
57-
65+
5866
- name: Create a GitHub release
5967
if: ${{ steps.get_commit.outputs.COMMIT_COUNT > 0 }}
6068
uses: actions/create-release@v1

0 commit comments

Comments
 (0)