Skip to content

Commit ac4bf93

Browse files
authored
Update release.yml
1 parent 73b3030 commit ac4bf93

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

.github/workflows/release.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,7 @@ jobs:
1414
- run: echo "Linting skipped"
1515

1616
release:
17-
name: Semantic Tag & GitHub Release
18-
# needs: lint ← ❌ REMOVE THIS LINE to prevent skipping
17+
name: Semantic Version Tag & Release
1918
runs-on: ubuntu-latest
2019

2120
steps:
@@ -53,25 +52,26 @@ jobs:
5352
git config user.name "Ripax"
5453
git config user.email "ripanbiswas007@gmail.com"
5554
git tag ${{ env.NEW_TAG }}
56-
git push origin ${{ env.NEW_TAG }}
55+
git push https://x-access-token:${{ secrets.PERSONAL_TOKEN }}@github.com/${{ github.repository }} ${{ env.NEW_TAG }}
5756
5857
- name: Generate changelog
5958
id: changelog
6059
run: |
60+
git log ${{ env.LATEST_TAG }}..HEAD --pretty=format:"- %s" > changelog.txt
6161
echo "CHANGELOG<<EOF" >> $GITHUB_ENV
62-
git log ${{ env.LATEST_TAG }}..HEAD --pretty=format:"- %s" >> $GITHUB_ENV
62+
cat changelog.txt >> $GITHUB_ENV
6363
echo "EOF" >> $GITHUB_ENV
6464
6565
- name: Update CHANGELOG.md
6666
run: |
6767
DATE=$(date +'%Y-%m-%d')
68-
echo -e "## [${{ env.NEW_TAG }}] - $DATE\n${{ env.CHANGELOG }}\n" | cat - CHANGELOG.md > temp && mv temp CHANGELOG.md
68+
echo -e "## [${{ env.NEW_TAG }}] - $DATE\n$(cat changelog.txt)\n" | cat - CHANGELOG.md > temp && mv temp CHANGELOG.md
6969
70-
git config user.name "github-actions"
71-
git config user.email "github-actions@github.com"
70+
git config user.name "Ripax"
71+
git config user.email "ripanbiswas007@gmail.com"
7272
git add CHANGELOG.md
7373
git commit -m "docs: update changelog for ${{ env.NEW_TAG }}"
74-
git push origin master
74+
git push https://x-access-token:${{ secrets.PERSONAL_TOKEN }}@github.com/${{ github.repository }} master
7575
7676
- name: Create release archives
7777
run: |

0 commit comments

Comments
 (0)