技巧精选

commit-rewriter 0.1 发布,用于编辑 Git 提交信息

commit-rewriter 0.1

精选理由

想快速清理 Git 仓库里的提交信息?这个工具能帮你自动处理,避免手动修改的麻烦。

这个工具能自动重写 Git 提交信息,移除编码过程中的杂乱内容。它通过创建时间戳分支来保存原始状态,方便回滚。用户可以通过命令行运行,指定仓库路径来使用。

原文 · Simon Willison’s Weblog

commit-rewriter 0.1

Release: commit-rewriter 0.1 I built this little web app the other day to help edit the commit messages for the Datasette security releases . The initial commits were full of coding agent cruft and references to issue IDs from our private repository, so they weren't fit for publication. If you want to edit the commit messages for a repository you can run it like this: uvx commit-rewriter path/to/repo Omit the path if you are already in the directory for that repo. When you submit your edits the tool creates a timestamped branch of your current repo state - to allow you to revert if you need to - and then rewrites every commit from the first one you edited to the most recent. Tags: git , projects , python , ai-assisted-programming