Run multiple Linux commands, one after the other

Run commands after another
Ex.

mkdir temp & cd temp & ls

Run commands after another if the previous command SUCCEEDS
Ex.

mkdir temp && cd temp && ls

Run commands after another if the previous command FAILS
Ex.

mkdir temp || echo 'mkdir failed'

Comments are closed.