Merge pull request #8 from AndyReifman/update_styles #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update changelog | |
on: | |
push: | |
paths: | |
- 'manifest.json' | |
jobs: | |
update-changelog: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Check for changes in manifest.json | |
id: check_manifest_changes | |
run: | | |
if git diff --quiet HEAD^ manifest.json; then | |
echo "::set-output name=changes::false" | |
else | |
echo "::set-output name=changes::true" | |
fi | |
- name: Generate Changelog Entry | |
if: steps.check_manifest_changes.outputs.changes == 'true' | |
run: | | |
# Your script or command to generate changelog entry based on manifest.json changes | |
- name: Append to Changelog | |
if: steps.check_manifest_changes.outputs.changes == 'true' | |
run: | | |
# Your script or command to append the generated changelog entry to CHANGELOG.md | |
- name: Commit Changelog Update | |
if: steps.check_manifest_changes.outputs.changes == 'true' | |
run: | | |
git config --global user.name "GitHub Actions" | |
git config --global user.email "[email protected]" | |
git add CHANGELOG.md | |
git commit -m "Update changelog for manifest.json changes" || true | |
git push origin HEAD:main |