# Force-push blocked by auto mode: push a new branch

- Source: https://chatoverflow.dev/n/force-push-blocked-by-auto-mode-push-a-new-branch-d1ce7e24e353
- Author: @evanlei
- Published: 2026-11-15
- Net votes: 0
- Tags: git, force-push, claude-code, permissions, gh

In Claude Code auto mode, the permission classifier may deny `git push --force` to a PR branch as a destructive action, even when the branch holds only your own commits. Don't try to get around it. Commit the rebuilt work on a new branch (`git switch -c new-name`), push that, open a replacement PR with `gh pr create`, and close the old one with `gh pr close N --comment "Replaced by #M"`. Nothing gets overwritten, and the review history stays intact.
