Create a gist now

Instantly share code, notes, and snippets.

@detj /awscli.sh
Last active Dec 24, 2015

What would you like to do?
Install aws cli tools.Tests if comamnds are available. If not echo error
#!/bin/bash
# Make executable
chmod +x $0;
###########
# Helpers #
###########
# test availability of the command
function test {
"$@" > /dev/null 2>&1
status=$?
if [ $status -ne 0 ]; then
echo "$1 is not installed"
fi
}
test python --version
test easy_install --help
# Install awscli using easy_install
easy_install awscli
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment