Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh function breaks after error
- X-seq: zsh-users 27504
- From: Thomas Lauer <thomas.lauer@xxxxxxxxxx>
- To: Roman Perepelitsa <roman.perepelitsa@xxxxxxxxx>
- Cc: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>, Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: zsh function breaks after error
- Date: Thu, 10 Feb 2022 17:20:32 +0000
- Archived-at: <https://zsh.org/users/27504>
- In-reply-to: <CAN=4vMrGe9oep-a-_5oqwnz0Fxyu5JtgbKfeNYUD=r0abnUicg@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- Organization: TL
- References: <l3850ht4v4mopd3asrkeuvpad65k2gi0j3@tlc.com> <CAH+w=7YwMwbo-HDOceDKX=oU4LQw9xg2Y_d9fWO9zk5hPummcA@mail.gmail.com> <e1u70ht8crjuu5l4f4saggu1rji626uns3@tlc.com> <CAH+w=7ZxtKCSCsmLqQovDGtPF-cbMi6um2JbVQhi7Zu8qOpZJQ@mail.gmail.com> <s16a0htkge5ug0f7aqqscfkq0d9couek3s@tlc.com> <CAN=4vMqx49BLiDJ13dqDgaHiSSvH96=mq2PUV3MgcAXt8c1Q_w@mail.gmail.com> <0oea0h1nt14oll0drq3450vng70ro0ga43@tlc.com> <CAN=4vMrGe9oep-a-_5oqwnz0Fxyu5JtgbKfeNYUD=r0abnUicg@mail.gmail.com>
> From: Roman Perepelitsa <roman.perepelitsa@xxxxxxxxx>
>
> This means that err_return option is set in your interactive zsh. This
> is likely the result of invoking a function that has `setopt
> err_return` in it without `emulate -L zsh` and without `setopt
> local_options`. That function needs to be fixed. For example, you
> could replace `setopt err_return` with `emulate -L zsh -o err_return`.
>
> You can read about zsh options and `emulate -L` here:
> https://zsh.sourceforge.io/Doc/Release/Options.html
Yep. Indeed, I have err_return set in my .zshrc (there are so many
options there that I have no idea when or even why I did include this).
Removed and things now work w/o "emulate -L zsh".
Appreciate your explanation and help. Tom
Messages sorted by:
Reverse Date,
Date,
Thread,
Author