Skip to content

Commit 934a7c6

Browse files
committed
Compute the tag just before we use it
1 parent 2ccf662 commit 934a7c6

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

.github/workflows/release-on-merge.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,6 @@ jobs:
1212
with:
1313
fetch-depth: 0
1414

15-
- name: Compute tag name
16-
id: compute-tag
17-
run: |
18-
echo Computing next tag number
19-
LASTPATCH=$(git describe --tags | cut -d- -f1 | cut -d. -f3)
20-
PATCH=$(($LASTPATCH+1))
21-
echo "::set-output name=tagname::2.1.${PATCH}"
22-
2315
- name: Set up Ruby
2416
uses: ruby/setup-ruby@v1
2517
with:
@@ -29,6 +21,14 @@ jobs:
2921
- name: Build release assets
3022
run: bundle exec rake book:build
3123

24+
- name: Compute tag name
25+
id: compute-tag
26+
run: |
27+
echo Computing next tag number
28+
LASTPATCH=$(git describe --tags | cut -d- -f1 | cut -d. -f3)
29+
PATCH=$(($LASTPATCH+1))
30+
echo "{tagname}={2.1.${PATCH}}" >> $GITHUB_OUTPUT
31+
3232
- name: Create release
3333
uses: ncipollo/release-action@v1
3434
with:

0 commit comments

Comments
 (0)