Exclude untracked workflow files from chack-agent auto-fix commits

This commit is contained in:
Carlos Polop
2026-02-11 15:35:18 +01:00
parent 354e3b81fb
commit 4650d6b8ad
2 changed files with 6 additions and 2 deletions

View File

@@ -125,7 +125,9 @@ jobs:
rm -f chack_failure_summary.txt chack_prompt.txt chack_failed_steps_logs.txt
git add -A
# Avoid workflow-file pushes with token scopes that cannot write workflows.
git restore --staged --worktree .github/workflows || true
git reset -- .github/workflows || true
git checkout -- .github/workflows || true
git clean -fd -- .github/workflows || true
git reset -- chack_failure_summary.txt chack_prompt.txt chack_failed_steps_logs.txt
if git diff --cached --quiet; then
echo "No committable changes left after filtering."

View File

@@ -182,7 +182,9 @@ jobs:
rm -f chack_failure_summary.txt chack_prompt.txt
git add -A
# Avoid workflow-file pushes with token scopes that cannot write workflows.
git restore --staged --worktree .github/workflows || true
git reset -- .github/workflows || true
git checkout -- .github/workflows || true
git clean -fd -- .github/workflows || true
git reset -- chack_failure_summary.txt chack_prompt.txt
if git diff --cached --quiet; then
echo "No committable changes left after filtering."