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

Re: [PATCH] fmt-merge-msg: use branch.$name.description

From
Jonathan Nieder <jrnieder@gmail.com>
Date
Oct 7, 2011, 20:12 UTC
Message-ID
<20111007201244.GB29712@elie.hsd1.il.comcast.net>
In-Reply-To
<4E8EED39.1060607@drmicha.warpmail.net>
Hi again,
Michael J Gruber wrote:
> I really haven't seen any convincing argument against yet. The details
> (note attached to refname object, or literal refanmes in the notes tree
> as per Jeff) should be discussed further, of course, but if branch
> descriptions aren't "notesy" then I don't know what is.

As mentioned before, I don't want to debate how Junio should spend his time (better for each person to provide relevant information and improvements to help out or to spend time on the alternatives one is interested in), but as a general question, this statement looked interesting to me.

"git notes" has a funny name, but deep down, as you know, it's about attaching additional versioned text to commit objects without changing their names. Branch descriptions are not per commit object (and as a mapping, the _keys_ are not shared), and personally I don't think they should be versioned any more than the branch names are.

I wanted to emphasize this because
	"git notes" is not the best tool for all annotations!
This ends this public service announcement.
Show 8 quoted lines
> Alternatively, one could store the description in a blob and refer to
> that directly, of course. I.e., have
>
> refs/description/foo
>
> point to a blob whose content is the description of the ref
>
> ref/foo

Sure, that would be a sane alternative design. It has the advantage of having the pumbing for fetching and pulling already set up, as you mention. The only disadvantages I know of are

 - "git branch -m" and "git remote rename" don't know about it yet
 - there's not one flat file you can edit to run a search/replace on
   all branch descriptions
and those aren't very serious problems.
>> I personally would prefer my branch descriptions to be non-versioned,
>> though I realize that is a matter of taste.
>
> Do you prefer you commit notes to be non-versioned?

No, I like them versioned. If I didn't, why wouldn't I have sent a patch to change that? Maybe some day there will be a "git notes log" tool to track the history of a note, taking changes in fanout into account.

Hope that clarifies a little.
Previous: Michael J GruberNext: Junio C Hamano
Message 10 of 12 in “fmt-merge-msg: use branch.$name.description”
  1. fmt-merge-msg: use branch.$name.descriptionJunio C Hamano, Oct 7, 2011
  2. Michael J GruberOct 7, 2011
  3. Jonathan NiederOct 7, 2011
  4. Michael J GruberOct 7, 2011
  5. Jonathan NiederOct 7, 2011
  6. Michael J GruberOct 7, 2011
  7. Jonathan NiederOct 7, 2011
  8. Junio C HamanoOct 7, 2011
  9. Michael J GruberOct 7, 2011
  10. Jonathan NiederOct 7, 2011
  11. Junio C HamanoOct 7, 2011
  12. Jakub NarebskiOct 8, 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.