I turned on
bash_completition today. Couldn't quite remember why I had it turned off. I quickly realized though. bash would fail on any filename with a square-bracket in it. It looks something like this:
~ $ touch 'test ' ~ $ ls<I HIT TAB HERE> bash: no match: test  ~ $
In other words, hitting TAB to tab-complete filenames would dump me back to a command prompt giving me that unhelpful error message, and I'd have to start the whole command over.
The problem was that I had this in my
shopt -s failglob
I can't for the life of me remember why that was in my
.bashrc. Clearly it wasn't doing anything I never had any use for, because this is the first time I got this "bash: no match" error. Removing that line makes
bash_completion work again though, so all is well.
This was a nightmare to debug too. Google was totally useless. I tracked it down to the
_filedir function in
/etc/bash_completition, and then it was trial-and-error. Next time I'm going to start off loading a clean login environment before I bother checking the system scripts for things. I did also learn that
set -v in a bash script makes it dump every line it executes to STDIN as it's executing them.