zsh-users
 help / color / mirror / code / Atom feed
From: Ray Andrews <rayandrews@eastlink.ca>
To: zsh-users@zsh.org
Subject: Re: zmv exits from function
Date: Tue, 2 Jan 2024 09:08:49 -0800	[thread overview]
Message-ID: <4350097c-ee24-42c5-8b12-c0cccb2f6542@eastlink.ca> (raw)
In-Reply-To: <1760392789.1738022.1704196204791@mail.virginmedia.com>


On 2024-01-02 03:50, Peter Stephenson wrote:
>> On 30/12/2023 20:38 GMT Bart Schaefer <schaefer@brasslantern.com> wrote:
>> Arguably zmv could use null_glob.  Thoughts from -workers?
> I guess the right thing to do regardless of option is that it should
> fail gracefully just by returning status 1 --- so not propagating the
> error to the caller.

That's just was I was trying to say :-)

There's a lot to be said for graceful failure.  If one wishes to crash 
the calling function one should  of course have that option, but why 
make it the default?  There's a sorta 'invisible return' there and the 
'always' thing counteracts it, but it all seems so unnecessary.  No 
invisible code, please.

BTW, just to whine, 'always' is sure hard to find in the help. One 
obviously can't just search for that word, and it doesn't show up in the 
list of reserved words neither.








  reply	other threads:[~2024-01-02 17:09 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-30 17:42 Ray Andrews
2023-12-30 20:38 ` Bart Schaefer
2023-12-30 21:02   ` Ray Andrews
2023-12-30 22:21     ` Bart Schaefer
2023-12-30 21:15   ` Mikael Magnusson
2023-12-31  3:43     ` Ray Andrews
2023-12-31  3:58       ` Bart Schaefer
2023-12-31 15:53         ` Ray Andrews
2023-12-31 21:44           ` Bart Schaefer
2023-12-31 22:06             ` Ray Andrews
2024-01-02 14:51               ` Mark J. Reed
2024-01-02 17:01                 ` Ray Andrews
2024-01-02 11:50   ` Peter Stephenson
2024-01-02 17:08     ` Ray Andrews [this message]
2024-01-02 17:47       ` Mark J. Reed
2024-01-02 18:16         ` Ray Andrews
2024-01-02 20:24           ` Bart Schaefer
2024-01-02 21:32             ` Ray Andrews
2024-01-02 17:48       ` Peter Stephenson
2024-01-02 19:07         ` Bart Schaefer
2024-01-02 19:52           ` Ray Andrews
2024-01-03  9:55           ` Peter Stephenson
2024-01-03 15:46             ` Ray Andrews
2024-01-03 19:01               ` Bart Schaefer
2023-12-30 22:34 ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4350097c-ee24-42c5-8b12-c0cccb2f6542@eastlink.ca \
    --to=rayandrews@eastlink.ca \
    --cc=zsh-users@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).