2

I'm trying to configure zshell in such a way that:

$ ls *<TAB>
# results in
ls a b c d e f g <cursor>

where "a, b, .., g" are the files that match the wildcard. Instead it gives me the default completion menu.

I do however want the completion menu if there is no glob to expand. So

$ ls * | <tab>

would give me the command completion menu.

I've seen this working. But I do not really no how to configure globbing in zshell. Anyone?

2
  • This is the default behavior with zsh 4.3.17 (both with the recommended and an empty .zshrc). Could you post the output of zstyle?
    – Dennis
    Commented Apr 12, 2013 at 18:56
  • Ah thank you. The one zshrc available online that I had not yet seen: the official example... I'll post an answer based on what I found. Commented Apr 12, 2013 at 19:28

1 Answer 1

2

As recommended by Dennis, I looked up the recommended default, which can be found here: offical default zshrc

I used their completion settings, and adapted them from there, so I can't tell for sure what did the trick. But I'm presuming this line was key:

# insert all expansions for expand completer
zstyle ':completion:*:expand:*' tag-order all-expansions
1
  • Thank you! It’s weird that compinstall doesn’t seem to include this setting. Commented Sep 24, 2020 at 22:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .