Ravi Sir's Cards › AWS
&& and or vs set -e
This comparison card contrasts && and or and set -e. && and or is described as per command choice. set -e is described as whole script stops. The card pairs && and or with key steps, and set -e with safety net everywhere.
Read card text
What this card says
Errors
&& and or
Per command choice.
set -e
Whole script stops.
Key points
Clear and local.
Has exceptions.
Example
cd /app && make
Use when
Key steps.
Safety net everywhere.