From: Felipe Contreras <felipe.contreras@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Git <git@vger.kernel.org>, "SZEDER Gábor" <szeder.dev@gmail.com>
Subject: Re: [PATCH] completion: bash: improve alias loop detection
Date: Tue, 17 Nov 2020 13:52:16 -0600 [thread overview]
Message-ID: <CAMP44s3dFZ4EjOgYd_e5JvNQWH_6bjLAHCYMa7n2kOFXWHCwcg@mail.gmail.com> (raw)
In-Reply-To: <xmqqtutn6ccp.fsf@gitster.c.googlers.com>
On Tue, Nov 17, 2020 at 12:57 PM Junio C Hamano <gitster@pobox.com> wrote:
>
> Felipe Contreras <felipe.contreras@gmail.com> writes:
>
> > It is possible for the name of an alias to end with the name of another
> > alias, in which case the code will incorrectly detect a loop.
> >
> > We can fix that by adding an extra space between words.
> >
> > Suggested-by: SZEDER Gábor <szeder.dev@gmail.com>
> > Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
> > ---
> > contrib/completion/git-completion.bash | 9 +++++----
> > 1 file changed, 5 insertions(+), 4 deletions(-)
>
> OK. An extra local variable would not hurt and makes the code
> easier to read.
It was there on v2. Which now may be a more reasonable sequence.
--
Felipe Contreras
prev parent reply other threads:[~2020-11-17 19:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-12 22:34 [PATCH] completion: bash: improve alias loop detection Felipe Contreras
2020-11-17 18:56 ` Junio C Hamano
2020-11-17 19:52 ` Felipe Contreras [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
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=CAMP44s3dFZ4EjOgYd_e5JvNQWH_6bjLAHCYMa7n2kOFXWHCwcg@mail.gmail.com \
--to=felipe.contreras@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--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.
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).