Rewrite commit history

Rewrite commit history in Git — with the four heights of help laid out: do it now, make it easier for the next person to accept, work out the right move when you are stuck, and learn the pattern so it stops coming back.

4prompt heights
Open it in the interactive atlas →

The four heights

The same task, four distances: today's deadline, the next reviewer, the stuck moment, the pattern.

Execute — do the immediate task

+
I need the project history rewritten so the bad API key never appears in any commit. Rewrite the…
I need the project history rewritten so the bad API key never appears in any commit. Rewrite the last 12 commits to remove the key, keep the authored dates and authors intact, and preserve merge commits where possible; stop and show the rewritten commits for verification before finalizing.

Improve — make it easier to accept

+
Before I rewrite history for the security scrub, make it easy for reviewers to approve: show a…
Before I rewrite history for the security scrub, make it easy for reviewers to approve: show a short summary of which commits will change, which files and lines contain the secret now, the risk if we delay, and a clear checklist of backups I should make so reviewers can sign off without fearing lost work.

Decide — diagnose the stuck moment

+
A recent scan flagged a secret in our main branch from three commits ago. I am worried rewriting…

I've noticed a secret leaked in recent commits.

A recent scan flagged a secret in our main branch from three commits ago. I am worried rewriting history will break teammates' work and CI, and I cannot tell who has local clones. What's the most likely safe approach to erase the secret while minimizing disruption, and what immediate communications and safeguards should I put in place?

Become — change the pattern

+
Across several repos, we repeatedly commit credentials, then rewrite history to remove them. This…

Secrets keep appearing in commits across projects.

Across several repos, we repeatedly commit credentials, then rewrite history to remove them. This costs hours, creates merge conflicts, and erodes trust. Which habit or process change would stop most of these incidents — a single guardrail that developers will actually follow — and how should I roll it out to engineering to avoid pushback?

Next to this one

Other version control work people do in Git.

Every task here came from the work, not from a feature list — which is why the prompts name what you want done and never the button that does it. The tool changes; the work does not.
Copyright © LLOS.ai · 2026 — original pedagogy, voice, and design — all rights reserved.

The rest of the map

Same library, five ways in.