git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sebastian Schuberth <sschuberth@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Jeff King <peff@peff.net>,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	git@vger.kernel.org
Subject: Re: [PATCH] Respect core.autocrlf when preparing temporary files for  external diff
Date: Sun, 22 Mar 2009 23:48:20 +0100	[thread overview]
Message-ID: <bdca99240903221548y38f31177q6abb88c2f7f87a73@mail.gmail.com> (raw)
In-Reply-To: <7vljqxcj84.fsf@gitster.siamese.dyndns.org>

> If you run "git diff <filename>" after cloning, I expect that no temporary
> files are involved, _unless_ you have some settings that force "git diff"
> not to use the internal diff.  Do you use GIT_EXTERNAL_DIFF?  Do you use
> "textconv" attribute?  What external program do you invoke from these
> mechanisms, and what does it expect to see as its input?

As I prefer graphical diff tools, I do not use internal diff, but
Beyond Compare [1]. In order to do that I have configured
diff.external to point to a wrapper script that contains the following
lines:

---8<---

#!/bin/bash

# diff is called with 7 parameters:
# path old-file old-hex old-mode new-file new-hex new-mode

"C:/Program Files/Beyond Compare 3/BCompare.exe" "$2" "$5" | cat

---8<---

As Beyond Compare is a stand-alone diff / merge tool, it expects to be
working on regular files in the file system. And to be hostest, I did
not know about the "textconv" attribute until now.

> The discussion in the last few messages in this thread speculates that the
> external programs are more likely to expect representations suitable in
> the work tree, aka "smudged", than "clean" one.  It would be nice to get a
> datapoint from you as the original reporter to confirm or refute that
> speculation.

I agree to the speculations. IMHO calling an external diff tool with
two revisions of a file should result in the same as e.g. checking out
the two revisions in two different working trees and then launching
the user's external diff tool on the two working tree files.

[1] http://www.scootersoftware.com/

-- 
Sebastian Schuberth

  reply	other threads:[~2009-03-22 22:49 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1237635609u.git.johannes.schindelin@gmx.de>
2009-03-21 11:42 ` [PATCH] Respect core.autocrlf when preparing temporary files for external diff Johannes Schindelin
2009-03-21 17:02   ` Michael J Gruber
2009-03-21 19:35   ` Junio C Hamano
2009-03-21 23:54     ` Johannes Schindelin
2009-03-22  0:03       ` Junio C Hamano
2009-03-22  0:41         ` Junio C Hamano
2009-03-22  6:10           ` Jeff King
2009-03-22  7:18             ` Junio C Hamano
2009-03-22  7:46               ` Jeff King
2009-03-22 15:30                 ` Sebastian Schuberth
2009-03-22 21:59                   ` Junio C Hamano
2009-03-22 22:48                     ` Sebastian Schuberth [this message]
2009-03-22 23:12                       ` Junio C Hamano
2009-03-23  0:39                 ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bdca99240903221548y38f31177q6abb88c2f7f87a73@mail.gmail.com \
    --to=sschuberth@gmail.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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 NNTP newsgroup(s).