I want to suppress errors in my sub-shell after a certain point.
I wrote script to demonstrate the situation:
worked=false (echo Starting subshell process \ && echo If this executes process is considered success \ && false \ && echo run if possible, but not an error if failed) \ && worked=true echo $worked
I want to report back to the outer shell that the process worked.
I also thought about putting the worked variable inside the subshell:
&& echo This works process worked: \ && worked=true \ && false \ && echo run if possible, but not an error if failed)
But this doesn't work either because setting a variable inside the subshell doesn't effect the main script.