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

Re: [PATCH] Make git-branch a builtin

From
Shawn Pearce <spearce@spearce.org>
Date
Oct 24, 2006, 06:55 UTC
Message-ID
<20061024065548.GB9947@spearce.org>
In-Reply-To
<7vy7r6qkmg.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <junkio@cox.net> wrote:
Show 17 quoted lines
> Shawn Pearce <spearce@spearce.org> writes:
> 
> >> > Wouldn't it make more sense to just include the full SHA1 of the
> >> > file we are deleting rather than the entire 131 line negative diff?
> >> 
> >> How would you do "git apply -R" on something like that?
> >
> > Uh, you have the full SHA1 in the index line.  So you just have to
> > reattach that blob to the named path...  pretty simple actually.
> 
> Bzzzt; wrong answer.
> 
> Think of a future when you can shallowly clone near the tip of
> git repository that does not have shell-script git-branch.sh
> anymore.  You cannot expect to already have the preimage of the
> patch in such a case.  You would still want to be able to revert
> the change with "git apply -R".

Yet another valid argument for having the data needed for the preimage available.

I've already agreed with Petr that having the data there is probably better than not. Now I'm also agreeing with you. There is little need to beat a dead horse. :-)

-- 
Shawn.
Previous: Junio C HamanoNext: Petr Baudis
Message 7 of 11 in “Make git-branch a builtin”
  1. Make git-branch a builtinLars Hjemli, Oct 23, 2006
  2. Shawn PearceOct 23, 2006
  3. Petr BaudisOct 23, 2006
  4. Junio C HamanoOct 23, 2006
  5. Shawn PearceOct 24, 2006
  6. Junio C HamanoOct 24, 2006
  7. Shawn PearceOct 24, 2006
  8. Petr BaudisOct 24, 2006
  9. Junio C HamanoOct 24, 2006
  10. Junio C HamanoOct 23, 2006
  11. Git-branch: fix regression and style issuesLars Hjemli, Oct 23, 2006

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.