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

Re: [PATCH] Add -r flag to show-diff for diff-cache/diff-tree like output.

From
Junio C Hamano <junkio@cox.net>
Date
Apr 27, 2005, 00:05 UTC
Message-ID
<7vd5shkrs5.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<Pine.LNX.4.58.0504261639420.18901@ppc970.osdl.org>
>>>>> "LT" == Linus Torvalds <torvalds@osdl.org> writes:
>> Later I'll add -p flag to diff-cache and diff-tree, so the usage
>> of these three commands match.

LT> The thing is, "-p" is strictly weaker than doing the UNIX LT> pipe way, since the latter trivially does the same time (add LT> a simple script if you don't want to type it), but can also LT> do things like "grep the filenames going past" or similar.

I do not disagree with that. Having only "-p" and not having diff-cache/tree output _is_ weaker, and I am _not_ advocating for removing the diff-cache/tree like output format from these three commands.

What I _am_ advocating for is to obsolete the diff-tree-helper program. What it does can be done, with the diff.[ch] change you merged this morning, without going through a pipe to the diff-tree-helper process but directly from these three commands, once diff-cache/tree acquires the "-p" flag.

By the way, how about renaming show-diff to diff-file?
    diff-tree  : compares two trees.
    diff-cache : compares a tree and the cache, or a tree and files.
    diff-file  : compares the cache and files.
Previous: Linus TorvaldsNext: Linus Torvalds
Message 17 of 22 in “Re: [GIT PATCH] Selective diff-tree”
  1. Linus TorvaldsApr 24, 2005
  2. David WoodhouseApr 24, 2005
  3. Linus TorvaldsApr 24, 2005
  4. Junio C HamanoApr 24, 2005
  5. Linus TorvaldsApr 24, 2005
  6. 0/2 diff-tree/diff-cache helperJunio C Hamano, Apr 25, 2005
  7. 1/2 Split external diff command interface to a separate file.Junio C Hamano, Apr 25, 2005
  8. 2/2 Introduce diff-tree-helper.Junio C Hamano, Apr 25, 2005
  9. Linus TorvaldsApr 26, 2005
  10. Nicolas PitreApr 26, 2005
  11. Junio C HamanoApr 26, 2005
  12. Diff-tree-helper take two.Junio C Hamano, Apr 26, 2005
  13. Add -r flag to show-diff for diff-cache/diff-tree like output.Junio C Hamano, Apr 26, 2005
  14. Linus TorvaldsApr 26, 2005
  15. Junio C HamanoApr 26, 2005
  16. Linus TorvaldsApr 26, 2005
  17. Junio C HamanoApr 27, 2005
  18. Linus TorvaldsApr 27, 2005
  19. diff-cache/tree compatible output for show-diff (take 2).Junio C Hamano, Apr 26, 2005
  20. Linus TorvaldsApr 27, 2005
  21. Linus TorvaldsApr 27, 2005
  22. Linus TorvaldsApr 27, 2005

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.