git_amend_commits
Apply commit message amendments from an inline YAML document, deterministically rewriting git history via amend or rebase. Refuses pushed commits unless explicitly allowed.
Instructions
Apply commit message amendments deterministically from an inline YAML document (no AI). This is the apply-messages-from-YAML counterpart to git_twiddle_commits: use git_twiddle_commits with dry_run = true to generate the amendments YAML, then pass it here to apply. Mutating: rewrites commit messages via git commit --amend / interactive rebase. Mirrors omni-dev git commit message amend. Commits already contained in a remote main branch are refused unless allow_pushed = true (rewriting published history).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| repo_path | No | Path to the git repository. Defaults to the current working directory. | |
| allow_pushed | No | When true, permits amending commits that already exist in a remote main branch (rewrites published history). Defaults to `false`, which refuses such commits — mirrors the CLI `--allow-pushed` flag. | |
| amendments_yaml | Yes | Amendments to apply, as an inline YAML document with an `amendments` list. Each entry needs `commit` (full 40-char SHA), `message` (the new message), and `summary` (may be empty), matching the YAML produced by `git_twiddle_commits` in `dry_run` mode. Applied deterministically — no AI is involved. |