Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh: RM_STAR warning counts files as though DOT_GLOB is set
- X-seq: zsh-workers 41674
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: "zsh-workers@xxxxxxx" <zsh-workers@xxxxxxx>
- Subject: Re: zsh: RM_STAR warning counts files as though DOT_GLOB is set
- Date: Mon, 11 Sep 2017 08:31:40 -0700
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=0ggKwvfJrXy/ykIY4LCwMmYPDHhG2N2NZNYaFym/JJ8=; b=D3+c5C2B/gq0topJW/0pTuJzbONgrCrFvgoIXwIca5hUM9ERbXnDpu1P4bNkESLXe2 vy40b5SJyI6B1grhWryVsjPo9DczF7K/vqV871tYUQHPO+alJCe0rcFSMlyav8qFUMFI qP/9BBu5aDFWz3+dF4y1PKW7i0dWxh90XuKxQloHMfpBPI78QXjR9KJgsxE4wV1/b8X+ kM63IuIiq5h42VQqcr3Q+GiWAi1oKMwxjUd6myGjsH8ek+gLb6rNBUPmBZV1zniXYGPF 998lM2wnahUKyiU0bcybcU6sxe+d6V21kXBvtU3wvhHiX1aT72Nb/VhTRQlz/MKEJU6D di1Q==
- In-reply-to: <20170911162337.630496ac@pwslap01u.europe.root.pri>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <20170911143436.GB1960@caska> <20170911150740.pz7fudj5lsflrmtk@tarpaulin.shahaf.local2> <CGME20170911152002epcas2p2c21e74cbd8645905fc8c6cf7680186da@epcas2p2.samsung.com> <1505143155.3891161.1102263072.1D722C8A@webmail.messagingengine.com> <20170911162337.630496ac@pwslap01u.europe.root.pri>
On Mon, Sep 11, 2017 at 8:23 AM, Peter Stephenson
<p.stephenson@xxxxxxxxxxx> wrote:
> On Mon, 11 Sep 2017 15:19:15 +0000
> Daniel Shahaf <danielsh@xxxxxxxxxx> wrote:
>> I don't understand the last branch of the if/else in that function: it
>> seems to prompt "... delete all the files ..." when count == 0?
>
> Apparently, yes. I think it's just covering the bases.
The issue here, as I recall, is that it's possible to have:
1 "rm *" is issued
2 chkrmall() finds no files in the directory
3 some external process creates a file
4 "rm *" is executed
5 the file created at (3) is silently deleted
So we would need either to avoid re-expanding "*" after chkrmall(), or
treat "found no files" as "user answered no".
Messages sorted by:
Reverse Date,
Date,
Thread,
Author