Re: [PATCH] completion: bash: improve alias loop detection
On Tue, Nov 17, 2020 at 12:57 PM Junio C Hamano <gitster@pobox.com> wrote:
Show 16 quoted lines
>
> 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