From: Jeff King <peff@peff.net>
To: Maaartin-1 <grajcar1@seznam.cz>
Cc: git@vger.kernel.org
Subject: Re: git-log combining different detail levels
Date: Wed, 22 Aug 2012 16:04:44 -0400 [thread overview]
Message-ID: <20120822200444.GA27462@sigill.intra.peff.net> (raw)
In-Reply-To: <50353212.7060109@seznam.cz>
On Wed, Aug 22, 2012 at 09:25:06PM +0200, Maaartin-1 wrote:
> Quite often I need to see some changes in more detail and others only
> briefly, so I get some idea about the context. For example I'd like
> something like merging the outputs of
>
> git log -p -S Bandersnatch
> and
> git log --name-status --oneline
>
> together, so I know better what happened.
>
> A simpler (and maybe more important) example is merging
>
> git log -p some/dir
> and
> git log --name-status
>
> so I could see all the changes, and the chosen ones with all details.
No, I don't think this is possible. We have "--full-diff", which
disconnects the path-limiting from the diff generation, so that:
git log --full-diff --name-status some/dir
would choose only commits for some/dir, but show the full diff of each
commit.
However, what you are asking is to disconnect the two diff options: one
verbose option only for interesting parts of the diff, and then a
more sparse option for the rest. I'm pretty sure the diff machinery does
not currently understand such an option.
It would not be impossible to implement, I think, but I suspect it would
involve refactoring the format selection in the diff code quite a bit.
In the meantime, one thing you can do is generate the full diff output
and then post-process it to collapse the uninteresting bits. I haven't
tried, but you can probably do something like this using "folds" in your
editor (e.g., shrink all of the diff content for a file to a single
line, but then expand it on demand).
-Peff
prev parent reply other threads:[~2012-08-22 20:04 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-22 19:25 git-log combining different detail levels Maaartin-1
2012-08-22 20:04 ` Jeff King [this message]
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=20120822200444.GA27462@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=grajcar1@seznam.cz \
/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).