Linux.com

Re: CLI Magic: For geek cred, try these one-liners

Posted by: David Tangye on July 24, 2008 05:55 AM
Hmmm, I always thought that the parentheses are not redundant: the subshell is needed so you do not change the current directory of the shell you are in, just the one that the output is to go to, and also the output of the tar create becomes input to the shell where tar extract runs, not where the cd statement is executed. If you remove the parentheses you are piping the tar output to a cd command, which is nonsense, then doing a tar x where its input stream will be your terminal.

[Modified by: David Tangye on July 24, 2008 06:07 AM]

#

Return to CLI Magic: For geek cred, try these one-liners