⬆️ Update dependencies: eslint packages (major) #754
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: Check if CHANGELOG is updated | |
on: | |
pull_request: | |
types: | |
- opened | |
- reopened | |
- synchronize | |
- ready_for_review | |
jobs: | |
check: | |
name: Did you update CHANGELOG? | |
if: ${{ ! github.event.pull_request.draft }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- shell: bash | |
run: | | |
readonly PR_URL='${{ github.server_url }}/${{ github.repository }}/pull/${{ github.event.pull_request.number }}' | |
readonly PR_URL_REGEX="\b${PR_URL//./\\.}\b" | |
if < "${GITHUB_WORKSPACE}/CHANGELOG.md" grep -Eq "${PR_URL_REGEX}"; then | |
: | |
else | |
echo 'The CHANGELOG.md file has not been updated! You must include this URL:' "${PR_URL}" >&2 | |
exit 1 | |
fi |