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

`rm *` count is incorrect with `setopt GLOB_DOTS`



Hello,

When I run `rm *`, zsh asks if I "want to delete all x files", where x 
is the number of files to be deleted. However, with `setopt GOB_DOTS`, 
this number appears to be two more than the actual number of files.

$ zsh -f
% cd $(mktemp -d)
% touch foo bar
% rm *
zsh: sure you want to delete all 2 files in /tmp/tmp.cLNHQwcBW1 [yn]? n
% setopt GLOB_DOTS
% rm *
zsh: sure you want to delete all 4 files in /tmp/tmp.cLNHQwcBW1 [yn]?

I'm testing with zsh 5.5 on Arch Linux. I also reverted back to zsh 
5.3.1, and this issue was still present. However, I get the feeling that 
this issue wasn't around since that long ago, so the source of the 
problem could be something else (apologies in advance if it is).

Cheers.

P.S. I'm not subscribed to the mailing list, so please reply to this 
email address.



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