man bash
says:
completion-map-case (Off)
If set to On, and completion-ignore-case is enabled, readline treats hyphens (-) and underscores (_) as equivalent when performing case-insensitive filename matching and completion.
$ bind -v|grep case
set completion-ignore-case on
set completion-map-case on
When I type
$ touch _test
$ chmod +x -t<TAB>
it completes to
$ chmod +x _test
But neither
$ ./-t<TAB>
$ ls -t<TAB>
complete.
Why is that and can it be fixed?
shopt -u progcomp
. I don't think that those settings work with the "programmable completion" which is now the default on many systems.ls -t
case but it still does not complete./-t