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

Pattern matching with _files vs command line



Hi,

With the file-patterns style unset and the following compdef:

#compdef foo

local expl ret=1

_wanted files expl file _files -g '*(-FM)' && ret=0

return ret

I see the following difference, is this expected or perhaps a bug?

% find
.
./empty
./full
./full/test.txt
./file.txt
% ls -d *(-FM)
full/
% foo <TAB>
empty   full    full/ 
% foo empty/

Both the double match for full and empty being offered were
unexpected to me.

Thanks,

-- 
Marko Myllynen



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