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

Re: git reset for index restoration?

From
Jeff King <peff@peff.net>
Date
May 22, 2014, 19:09 UTC
Message-ID
<20140522190959.GA18785@sigill.intra.peff.net>
In-Reply-To
<1400785669.18134.21.camel@stross>
On Thu, May 22, 2014 at 03:07:49PM -0400, David Turner wrote:
Show 10 quoted lines
> On Thu, 2014-05-22 at 14:39 -0400, Jeff King wrote:
> > does show some improvement. Perhaps "git reset" is not writing out the
> > cache-tree extension?
>  
> Yes, that seems to be exactly what is going on; the two indexes are
> identical up to the point where the TREE extension appears.
> 
> Thanks for clearing that up!  
> 
> Do you think that this is a bug in git reset?

Possibly. There is a call to prime_cache_tree in builtin/reset.c, which looks like it should trigger during a "mixed" or "hard" reset (and without arguments, you should have a mixed reset). But it doesn't seem to get called. I haven't traced it further.

-Peff
Previous: David TurnerNext: Jeff King
Message 10 of 22 in “git reset for index restoration?”
  1. David TurnerMay 22, 2014
  2. Jeff KingMay 22, 2014
  3. David TurnerMay 22, 2014
  4. Jeff KingMay 22, 2014
  5. David TurnerMay 22, 2014
  6. Elijah NewrenMay 22, 2014
  7. David TurnerMay 22, 2014
  8. Jeff KingMay 22, 2014
  9. David TurnerMay 22, 2014
  10. Jeff KingMay 22, 2014
  11. Jeff KingMay 22, 2014
  12. Junio C HamanoMay 22, 2014
  13. David TurnerMay 22, 2014
  14. Junio C HamanoMay 22, 2014
  15. David TurnerMay 22, 2014
  16. Junio C HamanoMay 22, 2014
  17. Junio C HamanoMay 22, 2014
  18. Duy NguyenMay 22, 2014
  19. David TurnerMay 22, 2014
  20. Junio C HamanoMay 22, 2014
  21. David TurnerMay 22, 2014
  22. Junio C HamanoMay 22, 2014

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.