Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] Add execute-command() widget function (was Re: [RFC][PATCH] Add change-directory() widget function)
- X-seq: zsh-workers 48717
- From: Marlon Richert <marlon.richert@xxxxxxxxx>
- To: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- Cc: Zsh hackers list <zsh-workers@xxxxxxx>
- Subject: Re: [PATCH] Add execute-command() widget function (was Re: [RFC][PATCH] Add change-directory() widget function)
- Date: Mon, 26 Apr 2021 21:08:38 +0300
- Archived-at: <https://zsh.org/workers/48717>
- In-reply-to: <CAH+w=7YTPm_5=8cPSydgte_Ti7UaihR4s+fOz0H97_4dZwCeiw@mail.gmail.com>
- List-id: <zsh-workers.zsh.org>
- References: <95CDA630-4EE5-4003-8D9C-CCCB9A47F109@gmail.com> <CAH+w=7bpkYktd4UN5DtUS45MMNdWYr7c-OG7DHOX21QXG4LMUA@mail.gmail.com> <4D587C0C-EB5F-4A58-A0AE-D45E43F432CD@gmail.com> <CAH+w=7bQLq43JChP7PmaqT_wHMwgs4Nk_-0grrtQXEhQJcfrbA@mail.gmail.com> <CAH+w=7ZCzG-BGZuU-rLoZJX=3zcA74NK+TNVDP-CWF-9b-BfrA@mail.gmail.com> <AEC92FEA-6216-4952-818E-9DC7C584698A@gmail.com> <20210421212717.GE21343@tarpaulin.shahaf.local2> <CAH+w=7bFfZucFRj9OZvzTnvxd+QUW7tZHAJiMLi+O0PNjz=wyA@mail.gmail.com> <214AC3E9-FFA5-4F39-A918-562682FE3A3B@gmail.com> <CAH+w=7ZSWhyogP=rn_O40Lc96jTnM4rAKkHaXLn5iOsS7F76Vg@mail.gmail.com> <CAHLkEDspzutwPTAqC7HqdAJDqF0FncsWH6NsHk5Z=bt+Jww8vg@mail.gmail.com> <CAH+w=7ZhNyZypwtMvgBcCkUwCLRzB1+XtccdYG14A1zVJsSTrg@mail.gmail.com> <CAH+w=7YTPm_5=8cPSydgte_Ti7UaihR4s+fOz0H97_4dZwCeiw@mail.gmail.com>
On Sun, Apr 25, 2021 at 12:58 AM Bart Schaefer
<schaefer@xxxxxxxxxxxxxxxx> wrote:
> execute-command () {
> case $CONTEXT in
> (cont|start) print -rz -- "$PREBUFFER$BUFFER"
> print -rS -- "${${(q-)@}}"
> eval "${(q-)@}" ;;
> (*) return 75 ;;
> esac
> zle .send-break
> }
I tried it and it's otherwise good, but that last line causes %? == 1
and %(? == true. Can that be fixed somehow?
Messages sorted by:
Reverse Date,
Date,
Thread,
Author