git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: Eric Raible <raible@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>, paulus@samba.org
Subject: Re: RFH: gitk equivalent of "git log -p --full-diff file.cpp"
Date: Mon, 6 Oct 2008 22:27:05 -0400	[thread overview]
Message-ID: <20081007022705.GA4496@coredump.intra.peff.net> (raw)
In-Reply-To: <279b37b20810061904n4f50f650l81590cb6fd239282@mail.gmail.com>

On Mon, Oct 06, 2008 at 07:04:14PM -0700, Eric Raible wrote:

> Anyway what I'm looking for is the gitk equivalent of:
> 
>     git log -p --full-diff file.cpp

Try turning off the option "Limit diffs to listed paths" in the
preferences menu (or adding "set limitdiffs 0" to your ~/.gitk).

> That is to say: I want to see all commits which touch a given
> file along with all of the other files changed by that commit.
> 
>     gitk -p --full-diff EntryPoints.cpp

You definitely don't want the "-p" here, which is what is causing the
extra diffs as part of the commit message. What happens is that gitk
actually gets the diff separately from the history (since it gets each
diff on the fly as you highlight it). The command line arguments go
towards getting the history; so gitk isn't expecting parse any diff (and
you will make gitk startup a _lot_ slower as it waits for git to
generate the diffs for every revision).

The "--full-diff" is simply ignored, since the actual diff happens
during a later command.  In theory, gitk could remember your --full-diff
and use it later. But I think for your use, the preference setting
is probably good enough.

> PS - Aside from aliases, am I missing a simpler spelling of the above
>      git log command?

Nope, it looks right to me. At one point, we discussed a "full-diff"
config option (and I think I maybe even posted a patch), but nobody
really cared.

-Peff

  reply	other threads:[~2008-10-07  2:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-07  2:04 RFH: gitk equivalent of "git log -p --full-diff file.cpp" Eric Raible
2008-10-07  2:27 ` Jeff King [this message]
2008-10-07  3:45   ` Eric Raible

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=20081007022705.GA4496@coredump.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=paulus@samba.org \
    --cc=raible@gmail.com \
    /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).