#if $thebool echo "The bool is true"; echo "The bool is really true" 1>&2; echo "This is a line of text." > $out_file1 #else echo "The bool is not true"; echo "The bool is very not true" 1>&2; echo "This is a different line of text." > $out_file1; sh -c "exit 2" #end if #if $failbool ; sh -c "exit 127" #end if