git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: Marcus Comstedt <marcus@mc.pp.se>
Cc: Lars Hjemli <hjemli@gmail.com>, git@vger.kernel.org
Subject: Re: git log --stat FILE
Date: Sun, 8 Aug 2010 15:08:53 +0200	[thread overview]
Message-ID: <201008081508.53732.jnareb@gmail.com> (raw)
In-Reply-To: <yf9bp9ds2mz.fsf@chiyo.mc.pp.se>

Marcus Comstedt wrote:
> Jakub Narebski <jnareb@gmail.com> writes:
> 
> > Diffstat is just a diff format (a way of presenting diff); '--stat'
> > is described in "Common _diff_ options" of git-log(1) manpage.
> >
> > But whats obvious to me might not be obvious to everyone.
> 
> To me (and probably many others), a "diff" is the output of the
> command "/usr/bin/diff".  I notice that git seems to refer to this as
> a "patch" instead.  Nevertheless, the documentation of --full-diff
> explicitly talks about "log -p", rather than "diffs" in general.  So
> it's not clear from the documentation that it affects other types of
> diffs than those produced by -p ("patches").

To me (and probably many others), a "diff" is something that describe
differences between two versions (compares two version).  Note that
'GNU diff' (and other "/usr/bin/diff") supports three output formats:
ed based, context and unified formats.  git-diff supports patch format
(unified, with some extensions), raw aka diff-tree format, and various
versions of diffstat format.

The '--full-diff' is a git-log option, not diff option, as it affects
how git-log uses path limiter.  "git log -p <path>..." is an example
of copmmand that shows diffs with commits, as "git log <path>..." alone
doesn't show diffs (in any format).  But perhaps the description of
'--full-diff' option could be improved.

The '--stat' is git-diff option, as you can see by running e.g.
"git diff --stat HEAD^!"

-- 
Jakub Narebski
Poland

  reply	other threads:[~2010-08-08 13:08 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-08 11:29 git log --stat FILE Marcus Comstedt
2010-08-08 11:54 ` Jakub Narebski
2010-08-08 11:54 ` Lars Hjemli
2010-08-08 12:04   ` Marcus Comstedt
2010-08-08 12:26     ` Jakub Narebski
2010-08-08 12:35       ` Marcus Comstedt
2010-08-08 13:08         ` Jakub Narebski [this message]
2010-08-08 13:33           ` Marcus Comstedt
2010-08-08 15:31             ` [PATCH] Documentation/git-log: Clarify --full-diff Michael J Gruber
2010-08-09  7:45               ` Matthieu Moy
2010-08-09 19:57                 ` 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=201008081508.53732.jnareb@gmail.com \
    --to=jnareb@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=hjemli@gmail.com \
    --cc=marcus@mc.pp.se \
    /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).