Skip to content

Commit

Permalink
Update changelog-pr.yml / Add Check
Browse files Browse the repository at this point in the history
  • Loading branch information
MickLesk authored Nov 17, 2024
1 parent a469647 commit aab8be4
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion .github/workflows/changelog-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ name: Create Changelog Pull Request
on:
push:
branches: ["main"]

workflow_dispatch:

jobs:
Expand Down Expand Up @@ -38,6 +37,19 @@ jobs:
echo "LATEST_DATE=$LATEST_DATE" >> $GITHUB_ENV
fi
- name: Check if CHANGELOG.md was modified
id: changelog-check
run: |
CHANGED_FILES=$(git diff --name-only ${{ github.event.before }} ${{ github.sha }})
echo "Changed files: $CHANGED_FILES"
if echo "$CHANGED_FILES" | grep -q 'CHANGELOG.md'; then
echo "Changes detected in CHANGELOG.md, skipping additional checks."
echo "changelog_modified=true" >> $GITHUB_ENV
else
echo "No changes to CHANGELOG.md, continuing with protection checks."
echo "changelog_modified=false" >> $GITHUB_ENV
fi
- name: Get categorized pull requests
id: get-categorized-prs
uses: actions/github-script@v7
Expand Down

0 comments on commit aab8be4

Please sign in to comment.