Clone and install go in the gos folder

This commit is contained in:
Joshua Bussdieker
2011-11-17 23:19:56 -08:00
parent dc5563dc15
commit 62e074f4f9
+5 -1
View File
@@ -1,8 +1,12 @@
#!/bin/bash
INSTALL_ROOT=~/.gvm/gos/go-$2
if [[ $1 == "install" ]]; then
if [[ -n $2 ]]; then
echo "Installing version $2"
echo " * Downloading..."
hg clone -u release.r$2 https://go.googlecode.com/hg/ $INSTALL_ROOT > /dev/null 2>&1
echo " * Compiling..."
cd $INSTALL_ROOT/src;./all.bash > /dev/null 2>&1
exit 0
else
echo "ERROR: Please specifiy the version"