File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -296,6 +296,10 @@ jobs:
296
296
pattern : sd-*
297
297
merge-multiple : true
298
298
299
+ - name : Get commit count
300
+ id : commit_count
301
+ run : echo "count=$(git rev-list --count HEAD)" >> $GITHUB_OUTPUT
302
+
299
303
- name : Get commit hash
300
304
id : commit
301
305
uses : pr-mpt/actions-commit-hash@v2
@@ -306,7 +310,10 @@ jobs:
306
310
env :
307
311
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
308
312
with :
309
- tag_name : ${{ env.BRANCH_NAME }}-${{ steps.commit.outputs.short }}
313
+ tag_name : >
314
+ ${{ github.ref_name == 'master' &&
315
+ format('release_{0}_{1}', steps.commit_count.outputs.count, steps.commit.outputs.short) ||
316
+ format('{0}-{1}', env.BRANCH_NAME, steps.commit.outputs.short) }}
310
317
311
318
- name : Upload release
312
319
id : upload_release
You can’t perform that action at this time.
0 commit comments