git history adds experimental history rewriting and split
Introduced 2026-04-20 · score 0.97
HOW TO USE IT
When you need to split a commit, run `git history split <commit>` and interactively choose hunks for a new parent commit; Git prompts for both commit messages. For rewriting a commit message, run `git history reword <commit>`.
git history split <commit>git history split <commit> [--dry-run] [--update-refs=(branches|head)] [--] [<pathspec>…]git history reword <commit> [--dry-run] [--update-refs=(branches|head)]WHY THIS HELPS
Split or rewrite commit history in a repository using Git's experimental history command.
REQUIREMENTS AND LIMITATIONS
- Version: 2.54.0
- Availability: experimental
- <commit> (required): Commit to split or reword.
- --dry-run: Print reference updates without updating references; necessary new objects are still written.
- --update-refs=(branches|head): `branches` updates descendant local branches; `head` updates only the current HEAD reference. These values are mutually exclusive. Defaults to `branches`.
- --: Separates options from pathspec arguments.
- <pathspec>…: Limits which changes may be split; nonmatching files remain in the original commit.
- Prerequisite: Use Git 2.54.0 or later for the documented command. `git history` is experimental; its behavior may change.
- Prerequisite: The command does not support histories containing merges or operations that can result in merge conflicts.
- Prerequisite: For `split`, selecting all hunks or no hunks is invalid because one resulting commit would be empty.
FIRST-PARTY EVIDENCE
- https://github.com/git/git/blob/v2.54.0/Documentation/RelNotes/2.54.0.adoc
- https://git-scm.com/docs/git-history/2.54.0
Check the installed version and the source before using it. Entry JSON