Created
September 19, 2008 04:55
-
-
Save jeremyBanks/11542 to your computer and use it in GitHub Desktop.
[2010-01] a script downloading python from svn, they're moving off that
This file contains hidden or 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/bash | |
version="${1:-"3.0"}" | |
release="${2:-"rc1"}" | |
repository="http://svn.python.org/projects/python/r${version//./}" | |
directory="python$version$release" | |
NUL="/dev/null" | |
if python$version --version &> "$NUL"; then | |
echo -n "Current $version-series release installed: " | |
python$version --version | |
echo | |
fi | |
echo "Installing Python $version$release" | |
echo | |
echo "Downloading release through Subversion..." | |
if svn co "$repository" "$directory" > "$NUL"; then | |
cd "$directory" | |
if (./configure; make) > "$NUL"; then | |
echo "altinstalling: requires sudo" | |
sudo make altinstall | |
else | |
echo "Build or configure failed." | |
fi | |
cd .. | |
else | |
echo "Download failed." | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment