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

Re: branch description

From
Johan Herland <johan@herland.net>
Date
Apr 16, 2008, 08:29 UTC
Message-ID
<200804161029.18601.johan@herland.net>
In-Reply-To
<1c5969370804152046h8d67630m697ca71b523b04d9@mail.gmail.com>
On Wednesday 16 April 2008, Matt Graham wrote:
Show 11 quoted lines
> On Tue, Apr 15, 2008 at 9:33 PM, Jakub Narebski <jnareb@gmail.com> wrote:
> >  I think it wouldb be better to put branches descriptions somewhere
> >  outside object repository, be it .git/info/ref_names of .git/config.
> 
> I agree that outside the object repository would be better.
> Propogating branch descriptions doesn't seem all that useful.  I
> wouldn't usually expect to want a branch for the same purpose as the
> upstream repository and it would seem weird to get a default
> description of it coming along with the branch.  Just like I give my
> branches my own name, I would expect to have to give them my own
> description.

On the contrary, when I clone/pull from some repo, I would very much like to have a copy of its branch description stored locally. Of course, these descriptions should be renamed along with their corresponding branch upon entering my repo. To illustrate: Suppose I clone/pull "refs/heads/foo" from a remote repo "bob". The branch will be stored as "refs/remotes/bob/foo" in my repo. Now, if "refs/heads/foo" on "bob" has a branch description, I would like to have that branch description copied into my repo, but referring to "refs/remotes/bob/foo" instead of "refs/heads/foo", of course.

Now, when it comes to my own local branches, I agree with you: If I make a new local branch "refs/heads/foo" that tracks "refs/remotes/bob/foo", I will probably not want git to copy the branch description automatically.

However, I do agree that putting branch description inside the working tree is not the right solution. So far, the best proposal I've seen, is Hommey's suggestion of storing the description after the sha1 in the ref file itself. Of course, git would have to be taught (a) to handle ref files with descriptions, and (b) to propagate descriptions along with refs.

...Johan
-- 
Johan Herland, <johan@herland.net>
www.herland.net
Previous: Matt GrahamNext: Jakub Narebski
Message 15 of 23 in “branch description”
  1. Stephen SinclairApr 15, 2008
  2. Russ DillApr 15, 2008
  3. Brian GernhardtApr 15, 2008
  4. Junio C HamanoApr 15, 2008
  5. Jeff KingApr 15, 2008
  6. Jeff KingApr 15, 2008
  7. Junio C HamanoApr 15, 2008
  8. Stephen SinclairApr 15, 2008
  9. Brian GernhardtApr 15, 2008
  10. Jakub NarebskiApr 16, 2008
  11. Jeff KingApr 16, 2008
  12. Stephen SinclairApr 16, 2008
  13. Mike HommeyApr 16, 2008
  14. Matt GrahamApr 16, 2008
  15. Johan HerlandApr 16, 2008
  16. Jakub NarebskiApr 18, 2008
  17. Johan HerlandApr 19, 2008
  18. Junio C HamanoApr 19, 2008
  19. Johan HerlandApr 19, 2008
  20. Jakub NarebskiApr 19, 2008
  21. Junio C HamanoApr 16, 2008
  22. Jakub NarebskiApr 16, 2008
  23. Jakub NarebskiApr 15, 2008

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.