I normally use ; to combine more than one command in a line, but some people prefer &&. Is there any difference? For example, cd ~; c
;
&&
cd ~; c
In cmd1 && cmd2, cmd2 is only executed if cmd1 succeeds (returns 0).
cmd1 && cmd2
cmd2
cmd1
In cmd1 ; cmd2, cmd2 is executed in any case.
cmd1 ; cmd2
Both constructs are part of a POSIX-compliant shell.