git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Elijah Newren <newren@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Elijah Newren via GitGitGadget <gitgitgadget@gmail.com>,
	Git Mailing List <git@vger.kernel.org>
Subject: Re: [PATCH] check-ignore: fix handling with negated patterns
Date: Mon, 17 Feb 2020 10:41:47 -0800	[thread overview]
Message-ID: <CABPp-BEbojaeYkSMR7vntW0SkWf6dVOko5H=jqT-Yv2USRerxA@mail.gmail.com> (raw)
In-Reply-To: <xmqqimk5ks39.fsf@gitster-ct.c.googlers.com>

On Mon, Feb 17, 2020 at 10:05 AM Junio C Hamano <gitster@pobox.com> wrote:
>
> "Elijah Newren via GitGitGadget" <gitgitgadget@gmail.com> writes:
>
> > From: Elijah Newren <newren@gmail.com>
> >
> > check-ignore was meant to check ignore rules the same way git status and
> > other commands would, and to report whether a path is excluded.  It
> > failed to do this (and generated a few bug reports), however, because it
> > did not account for negated patterns.
>
> I suspect that the above distorts history.  IIRC, it was meant as a
> tool to see which exact pattern in the exclude sequence had the
> final say for the given needle, written primarily as a debugging
> aid.  In that context, "This rule has the final say", whether the
> rule is a negative or positive, still means something.

I can reword it; how does the following sound?

check-ignore claims that it reports whether each path it is given is
excluded.  However, it fails to do so because it did not account for
negated patterns.


Also, I think the "This rule has the final say" functionality of the
tool might still be useful, so I kept it -- see my updates to the
--verbose flag (mentioned later in the commit message).

> It is just the behavior is _much_ less useful for those who want to
> know what the final say is, and I tend to agree that we probably are
> better off changing its output to reflect "so, are we ignoring the
> path after all? yes/no?" because we are pretty much done with
> debugging the exclude API implementation.

  reply	other threads:[~2020-02-17 18:42 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-17 16:15 [PATCH] check-ignore: fix handling with negated patterns Elijah Newren via GitGitGadget
2020-02-17 18:04 ` Junio C Hamano
2020-02-17 18:41   ` Elijah Newren [this message]
2020-02-17 20:41     ` Junio C Hamano
2020-02-17 21:07       ` Elijah Newren
2020-02-19 21:36         ` Junio C Hamano
2020-02-18 20:36 ` [PATCH v2] check-ignore: fix documentation and implementation to match Elijah Newren via GitGitGadget
2020-02-18 21:27   ` Junio C Hamano
2020-02-18 23:05   ` [PATCH v3] " Elijah Newren via GitGitGadget

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CABPp-BEbojaeYkSMR7vntW0SkWf6dVOko5H=jqT-Yv2USRerxA@mail.gmail.com' \
    --to=newren@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=gitster@pobox.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).