.github/workflows/check_changelog.yml in heroku_hatchet-7.3.4 vs .github/workflows/check_changelog.yml in heroku_hatchet-7.4.0
- old
+ new
@@ -1,13 +1,22 @@
name: Check Changelog
on:
- pull_request:
- types: [opened, reopened, edited, synchronize]
+ pull_request:
+ types: [opened, reopened, edited, labeled, unlabeled, synchronize]
+
jobs:
- build:
+ check-changelog:
runs-on: ubuntu-latest
+ if: |
+ !contains(github.event.pull_request.body, '[skip changelog]') &&
+ !contains(github.event.pull_request.body, '[changelog skip]') &&
+ !contains(github.event.pull_request.body, '[skip ci]') &&
+ !contains(github.event.pull_request.labels.*.name, 'skip changelog') &&
+ !contains(github.event.pull_request.labels.*.name, 'dependencies') &&
+ !contains(github.event.pull_request.labels.*.name, 'automation')
steps:
- - uses: actions/checkout@v1
- - name: Check that CHANGELOG is touched
- run: |
- cat $GITHUB_EVENT_PATH | jq .pull_request.title | grep -i '\[\(\(changelog skip\)\|\(ci skip\)\)\]' || git diff remotes/origin/${{ github.base_ref }} --name-only | grep CHANGELOG.md
+ - uses: actions/checkout@v3
+ - name: Check that CHANGELOG is touched
+ run: |
+ git fetch origin ${{ github.base_ref }} --depth 1 && \
+ git diff remotes/origin/${{ github.base_ref }} --name-only | grep CHANGELOG.md