In bash, autocompletion of paths has recently stopped working when issuing
vim commands where the path is deeper than two directories (it continues to work as expected with other commands, such as
For example, if I type
ls .config/btsync/bt and then press TAB, it expands to
If I type
vim .config/bt and then press TAB, it expands to
However, if I type
vim .config/btsync/bt and then press TAB, nothing happens (I would expect it to expand to
vim .config/btsync/btsync.conf, as in the
ls example, above.
I get the same issue when running as my own user and when running as su.
I read this post which mentioned an issue with older versions of bash-completion but I'm running 2.1-5.
UPDATE: After some additional testing, I've found that the root issue is that bash will only complete directory names, not filenames.
It turns out that
bash-completion was the overall cause. See my second comment on the accepted answer.
Any suggestions as to the potential cause of this behaviour would be gratefully received!