File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Update Changelog
2+
3+ on :
4+ workflow_dispatch :
5+ schedule :
6+ # Run at 3 during night
7+ - cron : ' 0 3 * * *'
8+
9+ jobs :
10+ generate_changelog :
11+ runs-on : ubuntu-latest
12+ name : Generate changelog for master branch
13+ steps :
14+ - uses : actions/checkout@v1
15+
16+ - name : Generate changelog
17+ 18+ with :
19+ token : ${{ secrets.GITHUB_TOKEN }}
20+
21+ - name : Commit files
22+ env :
23+ CI_USER : " github-actions[bot]"
24+ CI_EMAIL : " 41898282+github-actions[bot]@users.noreply.github.com"
25+ run : |
26+ git config --local user.email "$CI_EMAIL"
27+ git config --local user.name "$CI_USER"
28+ git add CHANGELOG.md && git commit -m 'Updated CHANGELOG.md' && $(echo "push=1" >> $GITHUB_ENV) || echo "No changes to CHANGELOG.md"
29+ - name : Push changes
30+ if : env.push == 1
31+ env :
32+ CI_USER : " github-actions[bot]"
33+ CI_EMAIL : " 41898282+github-actions[bot]@users.noreply.github.com"
34+ CI_TOKEN : ${{ secrets.GITHUB_TOKEN }}
35+ run : |
36+ git push "https://$CI_USER:[email protected] /$GITHUB_REPOSITORY.git" HEAD:master
You can’t perform that action at this time.
0 commit comments