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

Re: [PATCH] cogito: Avoid slowness when timewarping large trees.

From
Jeff King <peff@peff.net>
Date
Mar 24, 2006, 11:22 UTC
Message-ID
<20060324112246.GA5220@coredump.intra.peff.net>
In-Reply-To
<7v3bh814z4.fsf@assigned-by-dhcp.cox.net>
On Fri, Mar 24, 2006 at 03:01:35AM -0800, Junio C Hamano wrote:
> >   git-read-tree --reset "$base"
> Exactly.  That's what I meant.  Thanks.
Hmm. That doesn't actually work, though. If I have a history like this:

$ cg-init -m "initial" $ cg-tag initial $ echo contents >file $ cg-add file $ cg-commit -m "added file"

and I try this: $ echo changes >file $ git-read-tree --reset master $ git-read-tree -m -u master initial

I get this: fatal: Entry 'file' not uptodate. Cannot merge.

If I do an update-index before the second read-tree, then I simply get: fatal: Entry 'file' would be overwritten by merge. Cannot merge.

Is there something I'm missing, or is a 'git reset --hard' really what we want here (in that case, the fact that git reset changes the HEAD might be a problem)?

-Peff
Previous: Junio C HamanoNext: Shawn Pearce
Message 5 of 10 in “cogito: Avoid slowness when timewarping large trees.”
  1. cogito: Avoid slowness when timewarping large trees.Jeff King, Mar 24, 2006
  2. Junio C HamanoMar 24, 2006
  3. Jeff KingMar 24, 2006
  4. Junio C HamanoMar 24, 2006
  5. Jeff KingMar 24, 2006
  6. Shawn PearceMar 24, 2006
  7. Jeff KingMar 25, 2006
  8. Avoid slowness when timewarping large trees.Jeff King, Mar 25, 2006
  9. Petr BaudisMar 26, 2006
  10. Junio C HamanoMar 25, 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.