All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: git@vger.kernel.org
Subject: Re: git-show --stat on first commit
Date: Tue, 21 Nov 2006 17:18:15 +0100	[thread overview]
Message-ID: <ejv8pc$cig$1@sea.gmane.org> (raw)
In-Reply-To: slrnem694k.4lm.Peter.B.Baumann@xp.machine.xx

Peter Baumann wrote:

> On 2006-11-21, Santi Béjar <sbejar@gmail.com> wrote:
>> On 11/21/06, Andy Parkins <andyparkins@gmail.com> wrote:
>>> Hello,
>>>
>>> I'm sure this one will be known about already.  git-show --stat on the the
>>> first commit doesn't show anything.  I assume it's because git-diff-tree has
>>> nothing to diff against (although shouldn't that be an everything-new diff?).
>>>
>>> Given the above; does anyone have a suggestion for what I could use as a
>>> replacement?  Even just a list of the new files would be useful.

You can always use git-ls-tree

>> $ git show --stat --root
>>
>> In general the initial commit diff (or stat) is hidden, but perhaps it
>> make sense to show it in "git show", you asked fo this specifically.
> 
> Why not make --root the default? I also stumbled over this behaviour and
> even asked on this list.
> 
> In my opinion this will help new users which are supprised that they
> can't get the diff of the inital commit (which is totaly non-intuitiv behavior).
> 
> And one less "wart" to clean, which another thread is all about. :-)

Because for projects imported into git first commit diff is huge,
and not very interesting. By the way, git show by default doesn't show
diff for merges (you need --cc for that), nor rename detection (you need
-M for that).

But you can always set default diff-tree options, including --root, --cc
and -M in the show.difftree configuration variable (either in repo config,
or in user config). It is IMHO better solution than changing defaults.
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git


  reply	other threads:[~2006-11-21 16:17 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-21 13:41 git-show --stat on first commit Andy Parkins
2006-11-21 14:01 ` Jakub Narebski
2006-11-21 14:09 ` Santi Béjar
2006-11-21 16:08   ` Peter Baumann
2006-11-21 16:18     ` Jakub Narebski [this message]
2006-11-21 17:16       ` Peter Baumann
2006-11-21 18:14       ` Horst H. von Brand
2006-11-21 16:31     ` Linus Torvalds
2006-11-21 16:47       ` Shawn Pearce
2006-11-21 17:11       ` Peter Baumann
2006-11-21 17:20         ` Linus Torvalds
2006-11-21 18:38         ` Olivier Galibert
2006-11-21 18:42           ` Shawn Pearce
2006-11-21 19:05           ` Petr Baudis
2006-11-21 18:06       ` Petr Baudis
2006-11-21 18:16         ` Jakub Narebski
2006-11-21 18:21           ` Petr Baudis
2006-11-21 18:34             ` Shawn Pearce
2006-11-21 18:39             ` Andy Parkins
2006-11-21 18:48               ` Petr Baudis
2006-11-21 18:52                 ` Shawn Pearce
2006-11-21 19:04                   ` Petr Baudis
2006-11-21 19:31             ` Junio C Hamano
2006-11-21 20:03               ` Jakub Narebski
2006-11-23  9:25                 ` Andy Parkins
2006-11-24  7:49                   ` Jakub Narebski
2006-11-23  9:36               ` [PATCH] config option core.showroot to enable showing the diff of the root commit Peter Baumann
2006-11-23 20:52                 ` Junio C Hamano
2006-11-23 23:34                   ` Peter Baumann
2006-11-24  0:18                     ` Junio C Hamano
2006-11-24  1:30                       ` Junio C Hamano
2006-11-24  7:53                         ` Peter Baumann
2006-11-24  8:54                           ` Junio C Hamano
2006-11-24  9:04                             ` Peter Baumann
2006-11-21 18:39       ` git-show --stat on first commit Carl Worth
2006-11-21 19:15       ` 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='ejv8pc$cig$1@sea.gmane.org' \
    --to=jnareb@gmail.com \
    --cc=git@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.