bash: Lists

1 
1 3.2.3 Lists of Commands
1 -----------------------
1 
1 A 'list' is a sequence of one or more pipelines separated by one of the
1 operators ';', '&', '&&', or '||', and optionally terminated by one of
1 ';', '&', or a 'newline'.
1 
1    Of these list operators, '&&' and '||' have equal precedence,
1 followed by ';' and '&', which have equal precedence.
1 
1    A sequence of one or more newlines may appear in a 'list' to delimit
1 commands, equivalent to a semicolon.
1 
1    If a command is terminated by the control operator '&', the shell
1 executes the command asynchronously in a subshell.  This is known as
1 executing the command in the BACKGROUND.  The shell does not wait for
1 the command to finish, and the return status is 0 (true).  When job
1 control is not active (⇒Job Control), the standard input for
1 asynchronous commands, in the absence of any explicit redirections, is
1 redirected from '/dev/null'.
1 
1    Commands separated by a ';' are executed sequentially; the shell
1 waits for each command to terminate in turn.  The return status is the
1 exit status of the last command executed.
1 
1    AND and OR lists are sequences of one or more pipelines separated by
1 the control operators '&&' and '||', respectively.  AND and OR lists are
1 executed with left associativity.
1 
1    An AND list has the form
1      COMMAND1 && COMMAND2
1 
1 COMMAND2 is executed if, and only if, COMMAND1 returns an exit status of
1 zero.
1 
1    An OR list has the form
1      COMMAND1 || COMMAND2
1 
1 COMMAND2 is executed if, and only if, COMMAND1 returns a non-zero exit
1 status.
1 
1    The return status of AND and OR lists is the exit status of the last
1 command executed in the list.
1