Created
August 27, 2012 16:32
-
-
Save xaicron/3490145 to your computer and use it in GitHub Desktop.
install-capnm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
HTTP_GET_COMMAND="" | |
if [ `which curl` ]; then | |
HTTP_GET_COMMAND="curl -L" | |
elif [ `which wget` ]; then | |
HTTP_GET_COMMAND="wget -O -" | |
elif [ `perl -v | grep "5.1[3-9]"` ]; then | |
HTTP_GET_COMMAND="perl -MHTTP::Tiny -e 'print +HTTP::Tiny->new->get(shift)->{content}'" | |
else | |
echo "curl or wget not found"; | |
exit 1; | |
fi | |
$HTTP_GET_COMMAND http://cpanmin.us/ | perl - App::cpanminus |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment