Skip to content

Commit

Permalink
Update generate-app-headers.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
MickLesk authored Jan 10, 2025
1 parent d8931fe commit 1a9320c
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions .github/workflows/generate-app-headers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,17 @@ jobs:
echo "$(figlet $APP_NAME)" >> .app-headers
done
# Step 7: Commit and push changes (if any)
- name: Commit and push changes
# Step 7: Check if there are changes to commit
- name: Check for changes and commit
run: |
git diff --quiet -- .app-headers || git commit -am "[core]: update .app-headers to latest version"
git push origin update-app-headers --force
git diff --exit-code --quiet .app-headers
if [ $? -eq 1 ]; then
echo ".app-headers has been updated, committing changes."
git commit -am "[core]: update .app-headers to latest version"
git push origin update-app-headers --force
else
echo "No changes to .app-headers detected, skipping commit."
fi
# Step 8: Create Pull Request if changes detected
- name: Create Pull Request if changes detected
Expand Down

0 comments on commit 1a9320c

Please sign in to comment.