download a file.
# Download file
curl "<url>" -OL
# Download file & rename
curl "url" -o "<new_name>" -L
flag | description |
---|---|
-o <file_name> | write output with name <file_name> |
-O | write output as the same name |
-L | follow redirect allowed |
extract .tar.gz archive
tar -xzvf <your archive .tar.gz / .tgz>
tar -xzvf <your archive .tar.gz / .tgz> -C <output directory>
flag | description |
---|---|
-x | xtract |
-z | use gzip compression |
-v | verbose |
-f | the input file ... |
-C | the redirect |