[9fans] exit an rc script on any error; equivalent of bash's set -e
2 views
Skip to first unread message
Rudolf Sykora
unread,
Nov 16, 2009, 2:29:10 PM11/16/09
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Hello,
is there anything similar to the bash's set -e (that causes a script to terminate whenever any command in the script returns a failure) in rc? Or do I have to always write sth like command1 || exit
command2 || exit ... ?
Thank you Ruda
erik quanstrom
unread,
Nov 16, 2009, 2:34:14 PM11/16/09
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
see rc(1) invocation section. see -e. this can be set % flag e
- erik
Rudolf Sykora
unread,
Nov 16, 2009, 2:34:11 PM11/16/09
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Ok! rc -e script seems to be the way... I finally found it.