All of lore.kernel.org
 help / color / mirror / Atom feed
* [BUG] In git-log, --name-status flag overrides the --patch flag
@ 2020-12-20  4:23 Érico Rolim
  2020-12-21 13:16 ` Đoàn Trần Công Danh
  0 siblings, 1 reply; 4+ messages in thread
From: Érico Rolim @ 2020-12-20  4:23 UTC (permalink / raw)
  To: git

Hi!

When using the command

  git log --patch --name-status

It seems the name-status flag somehow overrides the patch flag, by which I mean
that I get the same output as simply running

  git log --name-status

It would be nice for the combination of these two flags to work, as it would
allow one to view both a summary of changed files as well as the changes
themselves, at the same time.

Happy holidays,
Érico

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [BUG] In git-log, --name-status flag overrides the --patch flag
  2020-12-20  4:23 [BUG] In git-log, --name-status flag overrides the --patch flag Érico Rolim
@ 2020-12-21 13:16 ` Đoàn Trần Công Danh
  2020-12-21 19:09   ` Junio C Hamano
  0 siblings, 1 reply; 4+ messages in thread
From: Đoàn Trần Công Danh @ 2020-12-21 13:16 UTC (permalink / raw)
  To: Érico Rolim; +Cc: git

On 2020-12-20 01:23:05-0300, Érico Rolim <erico.erc@gmail.com> wrote:
> Hi!
> 
> When using the command
> 
>   git log --patch --name-status
> 
> It seems the name-status flag somehow overrides the patch flag, by which I mean
> that I get the same output as simply running
> 
>   git log --name-status
> 
> It would be nice for the combination of these two flags to work, as it would
> allow one to view both a summary of changed files as well as the changes
> themselves, at the same time.

I'm not arguing if this your expectation is make sense or not,
however, the Documentation says something about "Show only"...

Anyway, --patch-with-raw provides more information than
--patch --name-status combined.
I guess it's too much information?

-- 
Danh

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [BUG] In git-log, --name-status flag overrides the --patch flag
  2020-12-21 13:16 ` Đoàn Trần Công Danh
@ 2020-12-21 19:09   ` Junio C Hamano
  2020-12-23 23:54     ` Đoàn Trần Công Danh
  0 siblings, 1 reply; 4+ messages in thread
From: Junio C Hamano @ 2020-12-21 19:09 UTC (permalink / raw)
  To: Đoàn Trần Công Danh; +Cc: Érico Rolim, git

Đoàn Trần Công Danh  <congdanhqx@gmail.com> writes:

> On 2020-12-20 01:23:05-0300, Érico Rolim <erico.erc@gmail.com> wrote:
>> Hi!
>> 
>> When using the command
>> 
>>   git log --patch --name-status
>> 
>> It seems the name-status flag somehow overrides the patch flag, by which I mean
>> that I get the same output as simply running
>> 
>>   git log --name-status
>> 
>> It would be nice for the combination of these two flags to work, as it would
>> allow one to view both a summary of changed files as well as the changes
>> themselves, at the same time.
>
> I'm not arguing if this your expectation is make sense or not,
> however, the Documentation says something about "Show only"...

Perhaps the documentation would need to be clarified?  I suspect
this is not very useful combination [*1*] and if this were years
ago, I would suggest making the command line error out, instead of
silently ignore one and keep the other one in effect.


[Footnote]

*1* "--patch --stat --summmary" was designed as the standard "both a
    summary as well as the changes".

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [BUG] In git-log, --name-status flag overrides the --patch flag
  2020-12-21 19:09   ` Junio C Hamano
@ 2020-12-23 23:54     ` Đoàn Trần Công Danh
  0 siblings, 0 replies; 4+ messages in thread
From: Đoàn Trần Công Danh @ 2020-12-23 23:54 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: Érico Rolim, git

On 2020-12-21 11:09:58-0800, Junio C Hamano <gitster@pobox.com> wrote:
> Đoàn Trần Công Danh  <congdanhqx@gmail.com> writes:
> 
> > On 2020-12-20 01:23:05-0300, Érico Rolim <erico.erc@gmail.com> wrote:
> >> Hi!
> >> 
> >> When using the command
> >> 
> >>   git log --patch --name-status
> >> 
> >> It seems the name-status flag somehow overrides the patch flag, by which I mean
> >> that I get the same output as simply running
> >> 
> >>   git log --name-status
> >> 
> >> It would be nice for the combination of these two flags to work, as it would
> >> allow one to view both a summary of changed files as well as the changes
> >> themselves, at the same time.
> >
> > I'm not arguing if this your expectation is make sense or not,
> > however, the Documentation says something about "Show only"...
> 
> Perhaps the documentation would need to be clarified?

Honestly, I think documentation is fine, "Show only"... should mean
only.

>
> I suspect
> this is not very useful combination [*1*] and if this were years
> ago, I would suggest making the command line error out, instead of
> silently ignore one and keep the other one in effect.

Although, I don't have strong opinion on this combination,
I would say yes, and we should error out for other combination like
--name-status --patch too. And Érico, in a reply to me, said he would
prefer seeing an error instead of silencely discard one option.
I'll look into the implementation in this weekend.

> 
> 
> [Footnote]
> 
> *1* "--patch --stat --summmary" was designed as the standard "both a
>     summary as well as the changes".

-- 
Danh

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-12-23 23:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-20  4:23 [BUG] In git-log, --name-status flag overrides the --patch flag Érico Rolim
2020-12-21 13:16 ` Đoàn Trần Công Danh
2020-12-21 19:09   ` Junio C Hamano
2020-12-23 23:54     ` Đoàn Trần Công Danh

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.