git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH v2 0/2] diff --no-index: support symlinks and pipes
@ 2017-01-13 10:20 Dennis Kaarsemaker
  2017-01-13 10:20 ` [PATCH v2 1/2] diff --no-index: follow symlinks Dennis Kaarsemaker
  2017-01-13 10:20 ` [PATCH v2 2/2] diff --no-index: support reading from pipes Dennis Kaarsemaker
  0 siblings, 2 replies; 5+ messages in thread
From: Dennis Kaarsemaker @ 2017-01-13 10:20 UTC (permalink / raw)
  To: git; +Cc: Dennis Kaarsemaker

git diff <(command1) <(command2) is less useful than it could be, all it outputs is:

diff --git a/dev/fd/63 b/dev/fd/62
index 9e6542b297..9f7b2c291b 120000
--- a/dev/fd/63
+++ b/dev/fd/62
@@ -1 +1 @@
-pipe:[464811685]
\ No newline at end of file
+pipe:[464811687]
\ No newline at end of file

Normal diff provides arguably better output: the diff of the output of the
commands. This series makes it possible for git diff --no-index to follow
symlinks and read from pipes, mimicking the behaviour of normal diff.

v1: http://public-inbox.org/git/20161111201958.2175-1-dennis@kaarsemaker.net/

Changes since the RFC/v1 patch:
- Following symlinks is now the default. I think an accurate summary of the
  discussion on v1 is that this behaviour is useful enough to be the default,
  but to add an escape hatch. That escape hatch is named --no-dereference, name
  stolen from gnu diff.
- Added tests and documentation

Specifically not changed:
These changes affect only diff --no-index. Using --no-dereference is an error
without --no-index.

Dennis Kaarsemaker (2):
  diff --no-index: follow symlinks
  diff --no-index: support reading from pipes

 Documentation/diff-options.txt |  7 +++++++
 diff-no-index.c                | 15 ++++++++++++---
 diff.c                         | 23 +++++++++++++++++++----
 diff.h                         |  2 +-
 t/t4053-diff-no-index.sh       | 40 ++++++++++++++++++++++++++++++++++++++++
 t/test-lib.sh                  |  4 ++++
 6 files changed, 83 insertions(+), 8 deletions(-)

-- 
2.11.0-234-gaf85957


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-01-13 23:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-13 10:20 [PATCH v2 0/2] diff --no-index: support symlinks and pipes Dennis Kaarsemaker
2017-01-13 10:20 ` [PATCH v2 1/2] diff --no-index: follow symlinks Dennis Kaarsemaker
2017-01-13 23:37   ` Junio C Hamano
2017-01-13 10:20 ` [PATCH v2 2/2] diff --no-index: support reading from pipes Dennis Kaarsemaker
2017-01-13 23:24   ` Junio C Hamano

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).