git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: sending changesets from the middle of a git tree

From
RARyan Anderson <ryan@michonline.com>
Date
Aug 15, 2005, 06:35 UTC
Message-ID
<20050815063502.GD7001@mythryan2.michonline.com>
In-Reply-To
<20050814040233.GC6844@mythryan2.michonline.com>
On Sun, Aug 14, 2005 at 12:02:33AM -0400, Ryan Anderson wrote:
Show 9 quoted lines
> On Sat, Aug 13, 2005 at 10:35:50PM -0500, Steve French wrote:
>
> > 2) There is no way to update the comment field of a changeset after it 
> > goes in (e.g. to add a bugzilla bug number for a bug that was opened 
> > just after the fix went in).
> 
> No, a commit is immutable.  You can use "git format-patch" to rebase things if
> you need.  I prefer to use "git format-patch --mbox", edit what I need
> to, then use git-applymbox to rebase it all against a clean tree.

Note (and I should have said this at first), doing it this way gives you the opportunity to combine a few changes if you want.

Use git-format-patch-script to pull out what you want, delete the diff from the bottom of the file, manually diff what you need using git-diff-script, and stick that back at the end of the file git-format-patch-script created.

This seems to be the easiest way to clean up your change history.
-- 
Ryan Anderson
  sometimes Pug Majere
Previous: Ryan AndersonNext: Linus Torvalds
Message 3 of 12 in “sending changesets from the middle of a git tree”
  1. Steve FrenchAug 14, 2005
  2. Ryan AndersonAug 14, 2005
  3. Ryan AndersonAug 15, 2005
  4. Linus TorvaldsAug 14, 2005
  5. Linus TorvaldsAug 14, 2005
  6. Junio C HamanoAug 14, 2005
  7. Petr BaudisAug 14, 2005
  8. Junio C HamanoAug 15, 2005
  9. Catalin MarinasAug 15, 2005
  10. Wolfgang DenkAug 17, 2005
  11. Junio C HamanoAug 17, 2005
  12. Catalin MarinasAug 15, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.