Zsh Mailing List Archive
Messages sorted by:
Re: rfc patch, abort rm instead of only removing the * from the cmdline
- X-seq: zsh-users 13150
- From: "Richard Hartmann" <richih.mailinglist@xxxxxxxxx>
- To: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- Subject: Re: rfc patch, abort rm instead of only removing the * from the cmdline
- Date: Mon, 18 Aug 2008 12:04:59 +0200
- Cc: zsh-users <zsh-users@xxxxxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=Fue3z6zbx26IkAaLoxLNfXKsoe44K3ploq9lhCZBTTM=; b=eE4rEdliuGK4f6l1vu+Ltsy8xLCYH13nza4lxZ/G1s4Ge5SfEvioqwslMamBUHLn6k j1pZcuvQ5SnZyH6icpHeGGJ4JlsPBeaO2S3DewJh2xZc0VWcj7176CB1HaeljSFzd5cA QEWTq773TZqdc3bXmZEsBMLq7pXqqv/r4+GAw=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=DTeLKSiQGX3+q4sT/HdpsbqH8QF5pzcbFKIu4PgqYvlmSTeJsvJl97iAMHhb1wVHnu vndZcIeCc3az0crHhcOgInqZppms9Dd2jNTBpziloolK8vgQVqkmwNeQH30L/CB+UJDo EjcY0gBBW6MxigHDMtY9R/kBV5+7ZLr9M17SI=
- In-reply-to: <080817134217.ZM29726@xxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <2d460de70808160858p5312805dlf1c9976a9b702a51@xxxxxxxxxxxxxx> <237967ef0808160902p4dbc6d73w6620f6c69471ea20@xxxxxxxxxxxxxx> <2d460de70808160914h2c3706ebs312a0bbd62afbf57@xxxxxxxxxxxxxx> <20080816205209.GA5176@xxxxxxxxxxxxxxx> <237967ef0808161358y5deae840xe3bd399d01d198f@xxxxxxxxxxxxxx> <20080817065717.GA5175@xxxxxxxxxxxxxxx> <237967ef0808151649j1d14ce23s1acad02da98fdfdf@xxxxxxxxxxxxxx> <080817134217.ZM29726@xxxxxxxxxxxxxxxxxxxxxx>
On Sun, Aug 17, 2008 at 22:42, Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> It having been this way for far more than a decade without anyone ever
> complaining before, I'm not sure "asap!" really applies.
Something to be in a certain state for a long time does mean it should
not be fixed. To qualify, I did mean 'with the next release', not 'release
emergency patches', though.
Also, I know several people who have had massive data loss due to
misunderstanding what a program wants to do, or even due to a bug,
and never bothered to file a bug. That is unfortunate, but a fact. So
the mere lack of feedback does not mean it did not happen. Neither
does it mean it did happen, of course. Yet, especially with such
counter-intuitve behaviour, are slow to file issues. Especially if they
are not sure what happened or notice a long time after the fact.
> The existing behavior really is what Paul Falstad wanted the shell to
> do, all those years ago. Like several of the very oldest features,
> it's rather woefully under-documented in the man pages. If you want
> to abort the whole command, you're supposed to interrupt it with ^C,
> not answer "n" -- the prompt is really just to give you an extra moment
> to think about what a stupid thing you might be about to do, not to
> second-guess your entire command line; compare the RM_STAR_WAIT option
> (which is a lot more recent).
I can't think of a situation where ZSH queries me if I want to do
something and answering no does anything other than stopping to
execute whatever it wanted to do. The CORRECT option is somewhat
special, but follows the same pattern.
Thus, not aborting the command completely is against most user's
expectations and as this can lead to data loss, it is better to default
to the save option.
> Ideally I suppose this prompt should work like the prompt for "correct",
> giving you "nyae" as choices so you can choose to abort or to edit your
> typo. Then it would be more obvious that "n" was not going to entirely
> whack the command.
I have been thinking about this, as well. A problem I see is that the
meanings of yes and no are exchanged in the two examples. This
will probably confuse users and a bit of muscle memory can destroy
To summarize, I think it is best to default to the save option which
is to simply stop executing and returning to the command line.
Messages sorted by: