I am using tmux and bash. I find that, at seemingly random intervals, my running shells have show-all-if-ambiguous set to on. This is a significant annoyance to me, since many of my operations are in directories with very large numbers of files, where the show-all behavior disrupts the screen state. I have set show-all-if-ambigous off in my .inputrc, and have never enabled anything like this in any config file. The problem occurs in apparently any long-running shell. Running bind 'set show-all-if-ambiguous off' successfully disables it again, but this is temporary.

Why does this behavior occur, and how can I make it stop?

  • Sounds like a bug in bash. If you figure out steps to reproduce the problem it should be reported to developers because it probably is memory corruption bug. Which version you have (bash --version)? I'm running version 4.3.48(1)-release and I've never seen anything like you describe. – Mikko Rantalainen Sep 19 '18 at 10:49

So, after struggling with it for a while, I eventually just set PROMPT_COMMAND="bind 'set show-all-if-ambiguous off'". Which is a hack and doesn't address the real issue, but does what I need, viz. "make it stop doing that".

  • that is a clever workaround but I would guess if you need hacks such as this, your shell is already corrupting its memory and may fail in some other unexpected way in the future unless the root cause is fixed. (I'm assuming that your diagnosis is correct and you do not have any code that turns that feature on and as a result, the only thing that can enable that feature is a memory corruption bug that accidentally writes to the memory location containing the current flag value in bash process.) – Mikko Rantalainen Sep 19 '18 at 10:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.