git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Eric Sunshine <sunshine@sunshineco.com>
To: "SZEDER Gábor" <szeder.dev@gmail.com>
Cc: Junio C Hamano <gitster@pobox.com>, Jeff King <peff@peff.net>,
	Git List <git@vger.kernel.org>
Subject: Re: [PATCH/RFC] Makefile: dedup list of files obtained from ls-files
Date: Wed, 24 Apr 2019 13:19:40 -0400	[thread overview]
Message-ID: <CAPig+cSU5L2NDgMPJ4PG2nd8j9=Pe_LXxukDsFmZTiV2wf-4EA@mail.gmail.com> (raw)
In-Reply-To: <20190424112550.GC8695@szeder.dev>

On Wed, Apr 24, 2019 at 7:26 AM SZEDER Gábor <szeder.dev@gmail.com> wrote:
> On second thought, however, I'm not sure that such a '--dedup' option
> would be all that useful in the above cases.  If the users have to
> adjust their 'git ls-files' invocation by specifying '--dedup' to
> avoid the same paths listed multiple times, then they might just as
> well remove the redundant options.  After all, a deleted file is
> inherently modified, and a modified file is inherently cached...

As a person who rarely, if ever, uses git-ls-files, I'm having trouble
understanding why de-duping isn't the default behavior when the
listing is otherwise not annotated (that is, when -t/-v/-f/--debug are
not used). Are consumers of an unannotated list able to derive any
additional useful information from the duplicate entries? If consumers
can't derive anything useful, then the duplication seems more an
accident of implementation (for the unannotated case) than a planned
feature, thus could be considered a bug worth fixing. And, the fix
would be to de-dup by default when unannotated, thus no need for a
--dedup option. (As for backward-compatibility concerns, I imagine
that existing consumers either don't care about the duplication or
already manually de-dup, but perhaps I'm not seeing the larger
picture.)

  reply	other threads:[~2019-04-24 18:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-21 13:19 [PATCH/RFC] Makefile: dedup list of files obtained from ls-files Junio C Hamano
2019-04-22  3:23 ` Eric Sunshine
2019-04-22  6:11   ` Junio C Hamano
2019-04-22 14:49 ` Jeff King
2019-04-22 17:15   ` Ramsay Jones
2019-04-23  1:18     ` Junio C Hamano
2019-04-23 20:21   ` SZEDER Gábor
2019-04-24  1:03     ` Junio C Hamano
2019-04-24 11:25       ` SZEDER Gábor
2019-04-24 17:19         ` Eric Sunshine [this message]
2019-04-25  0:59           ` 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='CAPig+cSU5L2NDgMPJ4PG2nd8j9=Pe_LXxukDsFmZTiV2wf-4EA@mail.gmail.com' \
    --to=sunshine@sunshineco.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    --cc=szeder.dev@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).