Search code examples
zshoh-my-zshzsh-completion

Never complete beyond ambiguous choices


I'm trying to figure out how to customize zsh completion so that it never completes beyond an ambiguous result by just hitting tab. Here's an example.

$ emacs f<TAB>
  food fool
(completes into)
$ emacs foo
  food fool

Importantly, if I press TAB after 'emacs foo' I would like zsh to beep instead of complete into the menu.

Thanks.


Solution

  • Descending into the completion menu is controlled via the AUTO_MENU option. This is a default option which can be turned off by setting in your .zshrc the 'no' prefixed option.

    setopt noautomenu
    

    ZSH Documentation: 16 Options