Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: less with subprocess
- X-seq: zsh-users 27186
- From: Vincent Lefevre <vincent@xxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: less with subprocess
- Date: Thu, 30 Sep 2021 21:22:11 +0200
- Archived-at: <https://zsh.org/users/27186>
- In-reply-to: <CAH+w=7ZN0pziTVeEvy-Sjf6J-NyjVoi_8cnR1j6nVXUMnAmCRA@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- Mail-followup-to: zsh-users@xxxxxxx
- References: <CAP+y1xDdPi=DHR0KNrdCRiroC-54ev8HhfPW5O+59ap1COLBSg@mail.gmail.com> <20210927233143.GA16620@gmx.de> <CAH+w=7YOFKGfihX5794JVxcXTtS_QrAFpHAmaAotJOAYO7JMzg@mail.gmail.com> <CAH+w=7ZVWU444iL0u_RLfa-ormZTos+7M8iUQo-QqowqioFzCg@mail.gmail.com> <20210928185230.GA7495@gmx.de> <CAH+w=7ZgPGYngBrDEwcGqjrJ8GuLZ0Pn6VO9jDjvWz=_MPTzrw@mail.gmail.com> <20210929130217.GB25513@cventin.lip.ens-lyon.fr> <CAH+w=7an7ATJ51o-67ztFX+ShfEbrf158+Xi7OPtrm0X82vSbg@mail.gmail.com> <CAP+y1xBb37u4OZgHjov=LS-AH4mnx2D27JQP799gH_hC3Xod4w@mail.gmail.com> <CAH+w=7ZN0pziTVeEvy-Sjf6J-NyjVoi_8cnR1j6nVXUMnAmCRA@mail.gmail.com>
On 2021-09-29 10:56:30 -0700, Bart Schaefer wrote:
> On Wed, Sep 29, 2021 at 7:47 AM Pier Paolo Grassi <pierpaolog@xxxxxxxxx> wrote:
> >
> > LF () { () { cat >|$1 &! less $1 ; kill $! } =(:) }
> >
> > find | LF
> >
> > unfortunately when hitting F then ctrl-c in less the find process is immediately killed
>
> You can get around that with
>
> LF <<(find)
This is much worse! Ctrl-C then [End] yields
zsh: suspended (tty input)
then "fg" makes the terminal unusable.
> There could be some more failsafe stuff in "LF". For example if you
> accidentally invoke it with stdin still connected to the terminal
> instead of to a pipe, "cat" will be stopped with SIGTTIN and left
> lurking.
The above issue?
--
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
Messages sorted by:
Reverse Date,
Date,
Thread,
Author