Skip to content

Commit 916da7c

Browse files
authored
Create action.yml
1 parent fdbb856 commit 916da7c

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

action.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: 'Create VERSION.txt'
2+
description: 'GitHub Action to write a release's tag name to VERSION.txt and include it in the release.'
3+
runs:
4+
using: "composite"
5+
steps:
6+
- name: "Write VERSION.txt"
7+
run: echo "${{ github.event.release.tag_name }}" > VERSION.txt
8+
shell: bash
9+
- name: "Commit to GitHub"
10+
run: |
11+
git config user.name github-actions
12+
git config user.email [email protected]
13+
git add .
14+
git commit -m "Release ${{ github.event.release.tag_name }}"
15+
git push origin HEAD:${{ github.event.release.target_commitish }}
16+
shell: bash
17+
- name: "Update and commit release tag"
18+
run: |
19+
git tag --force ${{ github.event.release.tag_name }}
20+
git push --force origin ${{ github.event.release.tag_name }}
21+
shell: bash

0 commit comments

Comments
 (0)