Nk_extract_tar_gz
Description
I always forget the flags for tar, so this makes it easier.
Example
[root@cloudvpsserver public_html]# nk_extract_tar_gz nk_toolkit.tar.gz index.html index.org nk_all_docroots.html nk_all_docroots.org ... ... ...
Code
nk_extract_tar_gz() { # nk_extract_tar_gz expects to be receive a domain as an argument. # Print message and exit if one isn't provided. if [ "$1" = "" ]; then echo "You must provide a tar.gz file" return 0 fi tarfile="$1" tar -xvf "$tarfile" }