[Top][All Lists]

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

why is dash confused with underscore in autocompletion?

From: L A Walsh
Subject: why is dash confused with underscore in autocompletion?
Date: Tue, 29 May 2018 14:32:51 -0700
User-agent: Thunderbird

I have 4 files in a dir:


When I do autocomplete:

 > ls remo<TAB>                # I get all 4 files listed:
 remove-oldver-rpms-in-dir.pl* remove_mounted_lv*
 remove_multiples*             remove_nocase_dupfonts*
 > ls remove                   # and 'remo' is extended to 'remove'

(fine so far)

then I add a dash (or minus), '-' and hit <TAB> again.

I'd expect it to autocomplete the entire filename for
'remove-oldver-rpms-in-dir.pl' since it is the only file with a dash
after 'remove', but instead, bash prompts me again as though there
is some ambiguity between a dash and an underline.

But there isn't. Indeed, adding a '*' after the dash and ENTER, and
ls shows only 1 file.

Is there some setting I've forgotten I've set that is enabling this
behavior?  I can't think of why I'd want it, since I really do want
it to complete the 1st filename.  It also doesn't limit the words to
ones w/underscore after 'remove' if I add '_', it still lists
'remove-old...' as a completion option.

So why is this happening and how can I turn it off?


reply via email to

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