Re: [9fans] p9p mk rc help

2013-11-20 Thread Tony Lainson
> What is the correct way of detecting failure exit status of > FOO_COMMAND (a networked operation) and ignoring exit status of > BAR_COMMAND? Perhaps something like this would work? target: fn ignore { $* || status=() } foo | ignore bar Tony

Re: [9fans] p9p mk rc help

2013-11-20 Thread erik quanstrom
On Wed Nov 20 10:57:46 EST 2013, arn...@skeeve.com wrote: > > ! ~ $st ?* ^ '|' ^ * > > Sheesh. I'm a long time Unix type and even to *me* that looks like > line noise. :-) ! ~ $status ?* ^ '|' ^ * ah, sorry. FTFY. - erik

Re: [9fans] p9p mk rc help

2013-11-20 Thread arnold
> ! ~ $st ?* ^ '|' ^ * Sheesh. I'm a long time Unix type and even to *me* that looks like line noise. :-) Arnold

Re: [9fans] p9p mk rc help

2013-11-20 Thread erik quanstrom
> target: prereq > FOO_COMMAND | BAR_COMMAND > st = $status > if (~ $st ?* ^ '|' ^ *) { > echo FOO_COMMAND failed > exit 3 } i think there a bug in this. a trailing ~ 1 1 or similar is necessary to clear the status from the if. alternately, how about replacing the if

[9fans] p9p mk rc help

2013-11-20 Thread dexen deVries
Hi list, apologies for the keyword overload ;-) I have a plan9port mkfile using Rc (MKSHELL=$PLAN9/bin/rc), a recipe contains pipeline: FOO_COMMAND | BAR_COMMAND. What is the correct way of detecting failure exit status of FOO_COMMAND (a networked operation) and ignoring exit status of BAR_COMMA