Home / Companies / RWX / Blog / Post Details
Content Deep Dive

Rewriting Git History with Signed Commits

Blog post from RWX

Post Details
Company
RWX
Date Published
Author
Dan Manges (Co-founder, CEO)
Word Count
1,598
Company Posts That Month
4
Language
English
Hacker News Points
-
Post removed?
No
Summary

To prepare the ABQ and Captain repositories for open-source release without exposing private issues and pull requests, the team rewrote Git history to replace outdated pull-request references, clean up verbose squash-merge messages, and preserve links to each original commit. Because commit-signature verification was enabled, contributors collaboratively ran a Ruby script that assigned each person responsibility for rewriting commits associated with their email addresses and signing their replacements. The script processed commits from oldest to newest, retained each original tree and mapped parent relationships to preserve identical file contents and history structure, reformatted messages to include original PR and commit identifiers, preserved co-author credit, and maintained an old-to-new hash mapping so it could resume or coordinate with other participants. Contributors pushed rewritten commits to a new branch while the script fetched updates and waited for commits authored by others, allowing the team to generate a fully signed replacement history in minutes. An alternative considered was creating placeholder issues for historical private pull requests, but rewriting history was chosen because it also improved commit-message quality.

Trends Found in this Post

No tracked trend matches for this post yet.

Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.