Re: [dev] [st][patch] externalpipe()

From: Alexander Huemer <alexander.huemer_AT_xx.vu>
Date: Fri, 20 Dec 2013 20:24:04 +0100

On Fri, Dec 20, 2013 at 08:21:34PM +0100, Alexander Huemer wrote:
> Hi Rob!
>
> On Fri, Dec 20, 2013 at 01:56:15PM +0000, Rob wrote:
> >
> > Attached is a patch which gives st the ability to spit out its current
> > screen text to another program. This can be added under shortcuts in
> > config.h, e.g.:
> >
> >
> > static Shortcut shortcuts[] = {
> > ...
> > { MODKEY, 'u', externalpipe, { .s = "xurls | dmenu -l 10 | xargs open" } },
> > };
>
> IMHO it makes sense here to use `xargs -r`, otherwise hitting escape in
> dmenu results in calling `open` without argument, which does not make
> much sense.
>
> > Where xurls[1] is a script that pulls out urls from the text, then I
> > can pick one in dmenu and open[2] it in a browser.
>
> Very cool, thanks for writing this. I wanted to hack something
> equivalent to [1] during 30C3, which I won't now because this is much
> cooler :)

Sorry, [1] was missing.

Kind regards,
-Alex

[1] https://raw.github.com/muennich/urxvt-perls/master/url-select
Received on Fri Dec 20 2013 - 20:24:04 CET

This archive was generated by hypermail 2.3.0 : Fri Dec 20 2013 - 20:36:06 CET