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

Re: Retrieving a file in git that was deleted and committed

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 11, 2018, 01:19 UTC
Message-ID
<xmqq8t0woo6y.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<20181208072915.GA20697@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
> You can feed a set of revisions to git-blame with the "-S" option, but I
> don't offhand know how it handles diffs (I think it would have to still
> diff each commit against its parent, since history is non-linear, and a
> list is inherently linear).

It would diff each commit against its parent specified by the file given to the -S option. The contents of the file is fed directly to the graft mechanism to make the fake history in effect while the "blame" runs, and you are not limited to a linear history.

Previous: biswaranjan pandaNext: Elijah Newren
Message 9 of 12 in “Retrieving a file in git that was deleted and committed”
  1. biswaranjan pandaDec 7, 2018
  2. Bryan TurnerDec 7, 2018
  3. biswaranjan pandaDec 7, 2018
  4. Jeff KingDec 7, 2018
  5. Bryan TurnerDec 7, 2018
  6. biswaranjan pandaDec 7, 2018
  7. Jeff KingDec 8, 2018
  8. biswaranjan pandaDec 9, 2018
  9. Junio C HamanoDec 11, 2018
  10. Elijah NewrenDec 10, 2018
  11. Jeff KingDec 11, 2018
  12. Sergey OrganovDec 10, 2018

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.