help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Exclude builtins from command completion


From: kaycee gb
Subject: Re: Exclude builtins from command completion
Date: Fri, 17 Jan 2020 21:18:28 +0000

Le Fri, 17 Jan 2020 13:59:14 -0500,
Chet Ramey <address@hidden> a écrit :

> On 1/17/20 12:18 PM, kaycee gb wrote:
> 
> > When I was trying to achieve that, by accident I entered a colon ":" at an
> > empty prompt. I expected that it will do nothing but in fact that lists all
> > files in the current directory.
> 
> This comes up every now and then.
> 
> http://lists.gnu.org/archive/html/bug-bash/2003-01/msg00088.html
> https://lists.gnu.org/archive/html/bug-bash/2016-12/msg00029.html
> https://lists.gnu.org/archive/html/bug-bash/2019-06/msg00038.html
> 
> In this case, readline completes an empty filename.
> 
> 
Removing colon from wordbreaks COMP_WORDBREAKS=${COMP_WORDBREAKS//:} now do
nothing. 

By curiousity, why other breakwords do not have the same comportment ? Some do
nothing, some list files from CWD, some list all commands from my custom list.
Is there a place where I can have simple information for that ?

Moreover, the links above talks about filename completion. In this case isn't
it command completion ? Shouldn't it behave differently ? Or like in E13,
filename completion and command completion enter in word completion in
general ? 

And last, with COMP_WORDBREAKS empty, quote and double quote continue to list
files from CWD. Others do nothing. Shouldn't all do nothing ? 

kaycee,



reply via email to

[Prev in Thread] Current Thread [Next in Thread]