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

Re: [RFC/PATCH] commit notes workflow

From
Jeff King <peff@peff.net>
Date
Mar 1, 2011, 22:23 UTC
Message-ID
<20110301222350.GA24215@sigill.intra.peff.net>
In-Reply-To
<1299017913.14490.10.camel@drew-northup.unet.maine.edu>
On Tue, Mar 01, 2011 at 05:18:33PM -0500, Drew Northup wrote:
> A notes message which contains "the usual template stuff" as means of
> describing a change to it, for starters...

But we strip that from the notes, unless you use --cleanup. But in that case, you would have deleted the template cruft, since it pollutes your message.

> There is likely good reason why the commit message already has an end
> mark, I suspect that also applies here.

It doesn't have an end mark. The "usual template stuff" just happens to be at the end. But any line starting with "#" will be removed unless you use --cleanup, whether you use --notes or no. Similarly, unadorned lines after the "#" lines will be counted as part of the message.

> (Unless you count "---" between the commit message and the patch as
> "the usual template stuff"--which wasn't clear at this keyboard
> anyway.)

No, I meant the "#" lines. The "---" of format-patch isn't relevant here, since we're just talking about commit messages inside the editor during git-commit.

The really evil bit is "-v" which appends a giant diff with no real indication that it isn't part of the commit message. We already get rid of it with some heuristics (which I remember improving a while back). I don't think my RFC patch handles it very well, but that is something I will be looking at for the next revision.

-Peff
Previous: Drew NorthupNext: Drew Northup
Message 23 of 27 in “commit notes workflow”
  1. commit notes workflowJeff King, Feb 25, 2011
  2. Johan HerlandFeb 25, 2011
  3. Jeff KingMar 1, 2011
  4. Johan HerlandMar 2, 2011
  5. Sverre RabbelierMar 3, 2011
  6. Junio C HamanoMar 3, 2011
  7. Sverre RabbelierMar 3, 2011
  8. commit, status: #comment diff output in verbose modeIan Ward Comfort, Mar 3, 2011
  9. Sverre RabbelierMar 3, 2011
  10. Jeff KingMar 7, 2011
  11. 1/2 notes: make expand_notes_ref globally accessibleJeff King, Mar 7, 2011
  12. Johan HerlandMar 8, 2011
  13. 2/2 commit: allow editing notes in commit message editorJeff King, Mar 7, 2011
  14. Johan HerlandMar 8, 2011
  15. Michel LespinasseMar 8, 2011
  16. Chris PackhamMar 2, 2011
  17. Drew NorthupMar 2, 2011
  18. Piotr KrukowieckiMar 2, 2011
  19. Junio C HamanoFeb 25, 2011
  20. Drew NorthupFeb 25, 2011
  21. Jeff KingMar 1, 2011
  22. Drew NorthupMar 1, 2011
  23. Jeff KingMar 1, 2011
  24. Drew NorthupMar 1, 2011
  25. Michael J GruberFeb 27, 2011
  26. Jeff KingMar 1, 2011
  27. Yann DirsonMar 9, 2011

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.