Skip to content

Instantly share code, notes, and snippets.

@babo
Created October 30, 2013 07:56
Show Gist options
  • Save babo/7228703 to your computer and use it in GitHub Desktop.
Save babo/7228703 to your computer and use it in GitHub Desktop.
Install aws tool from Tim Kay with required CPAN modules
#!/bin/sh
if [ $(id -u) -ne 0 ]
then
echo 'Please run it as root'
exit 99
fi
for X in CPAN JSON XML::Simple
do
cpan -i ${X}
done
which aws > /dev/null
if [ $? -eq 0 ]
then
WHERE=`which aws`
else
WHERE='/usr/local/bin/aws'
fi
set -e
curl -o /tmp/aws https://raw.github.com/timkay/aws/master/aws
chmod +x /tmp/aws
mv /tmp/aws ${WHERE}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment