Skip to content

Instantly share code, notes, and snippets.

@baweaver
Created November 3, 2013 00:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save baweaver/7285105 to your computer and use it in GitHub Desktop.
Save baweaver/7285105 to your computer and use it in GitHub Desktop.
I get really annoyed at having to retype this exact same thing to install every tar.gz package, so I put it in a function
function pk-install {
url="$1"
wget $url
file_name=`echo $url | sed 's/^.*\/\(.*\)\.tar\.gz$/\1/'`
tar -zxvf "$file_name.tar.gz"
cd $file_name
make && make install
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment