Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

[bug?] How to make _expand behave like the expand-word or list-expand widgets?



I would expect _expand to behave by default like expand-word or list-expand, but it doesn't.

For example, given default shell options, if `foo=*`, then expand-word and list-expand will complete `$foo` to `*` and `$~foo` to the files matched by `*` as a glob _expression_.

However, no matter what zstyle options I set, _expand will either complete both of these to `\*` or both of these to the files globbed by `*`. 

By default, I would expect _expand to complete expressions in the same way as the shell substitutes them when evaluating the command line. 

Is there a combination of zstyles that makes _expand complete `$foo` to its literal value and `$~foo` to the files globbed by its value?

If not, then I would like to see this being added somehow and preferably be made the default behavior.



Messages sorted by: Reverse Date, Date, Thread, Author