) is, with few exceptions, the status code returned by the last command executed on the command line - in this case, this is the
command. Thus, since it [the command] is a pipe, the RC from the first command on the CLI is unobtainable using the command in the form shown because the first command completes moments prior to the tee command. to address your questions...