Re: xargs short-circuit

2012-02-18 Thread Matthew Story
On Tue, Feb 14, 2012 at 3:25 PM, Matthew Story wrote: > On Tue, Feb 14, 2012 at 2:37 PM, Matthew Story wrote: > >> On Tue, Feb 14, 2012 at 2:35 PM, Jilles Tjoelker wrote: >> >>> On Tue, Feb 14, 2012 at 01:34:49PM -0500, Matthew Story wrote: >>> > After reading the man-page, and browsing around th

Re: xargs short-circuit

2012-02-14 Thread Jos Backus
If you're able to install a port, it has a tool called shmux which you can invoke with `-r sh', it may do what you want. Jos -- Jos Backus jos at catnook.com ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-

Re: xargs short-circuit

2012-02-14 Thread Matthew Story
On Tue, Feb 14, 2012 at 2:37 PM, Matthew Story wrote: > On Tue, Feb 14, 2012 at 2:35 PM, Jilles Tjoelker wrote: > >> On Tue, Feb 14, 2012 at 01:34:49PM -0500, Matthew Story wrote: >> > After reading the man-page, and browsing around the internet for a >> minute, >> > I was just wondering if there

Re: xargs short-circuit

2012-02-14 Thread Matthew Story
On Tue, Feb 14, 2012 at 2:35 PM, Jilles Tjoelker wrote: > On Tue, Feb 14, 2012 at 01:34:49PM -0500, Matthew Story wrote: > > After reading the man-page, and browsing around the internet for a > minute, > > I was just wondering if there is an option in (any) xargs to > short-circuit > > on first f

Re: xargs short-circuit

2012-02-14 Thread Jilles Tjoelker
On Tue, Feb 14, 2012 at 01:34:49PM -0500, Matthew Story wrote: > After reading the man-page, and browsing around the internet for a minute, > I was just wondering if there is an option in (any) xargs to short-circuit > on first failure of [utility [arguments]]. > e.g. > $ jot - 1 10 | xargs -e -n

RE: xargs short-circuit

2012-02-14 Thread Devin Teske
> -Original Message- > From: owner-freebsd-hack...@freebsd.org [mailto:owner-freebsd- > hack...@freebsd.org] On Behalf Of Matthew Story > Sent: Tuesday, February 14, 2012 11:18 AM > To: freebsd-hackers@freebsd.org > Subject: Re: xargs short-circuit > > On Tue,

Re: xargs short-circuit

2012-02-14 Thread Matthew Story
> To: freebsd-hackers@freebsd.org > > Subject: xargs short-circuit > > > > After reading the man-page, and browsing around the internet for a > minute, > > I was just wondering if there is an option in (any) xargs to > short-circuit > > on first failure of [utility [a

RE: xargs short-circuit

2012-02-14 Thread Devin Teske
> -Original Message- > From: owner-freebsd-hack...@freebsd.org [mailto:owner-freebsd- > hack...@freebsd.org] On Behalf Of Matthew Story > Sent: Tuesday, February 14, 2012 10:35 AM > To: freebsd-hackers@freebsd.org > Subject: xargs short-circuit > > After r

Re: xargs short-circuit

2012-02-14 Thread Matthew Story
On Tue, Feb 14, 2012 at 1:34 PM, Matthew Story wrote: > After reading the man-page, and browsing around the internet for a minute, > I was just wondering if there is an option in (any) xargs to short-circuit > on first failure of [utility [arguments]]. > > e.g. > > $ jot - 1 10 | xargs -e -n1 sh -

xargs short-circuit

2012-02-14 Thread Matthew Story
After reading the man-page, and browsing around the internet for a minute, I was just wondering if there is an option in (any) xargs to short-circuit on first failure of [utility [arguments]]. e.g. $ jot - 1 10 | xargs -e -n1 sh -c 'echo "$*"; echo exit 1' worker || echo $? 1 1 such that any non