Skip to content

Instantly share code, notes, and snippets.

@oblique63
Created November 6, 2010 22:25
Show Gist options
  • Save oblique63/665761 to your computer and use it in GitHub Desktop.
Save oblique63/665761 to your computer and use it in GitHub Desktop.
Automates installation of Clojure [most current version] on a fresh Ubuntu system
# Be sure to place this script in the directory where you wish to install Clojure
sudo apt-get install sun-java6-jdk ant git
echo 'JAVA_HOME="/usr/lib/jvm/java-6-sun/" && export JAVA_HOME' >> ~/.profile
source ~/.profile
git clone https://github.com/clojure/clojure.git && cd clojure && ant
echo "java -cp `pwd`/clojure.jar clojure.main $@" > clojure
chmod +x clojure && sudo ln -s `pwd`/clojure /usr/bin/clojure
# Temporary convenience
alias clojure="`pwd`/clojure"
cd ..
echo "Setup is complete. You may now run the 'clojure' command."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment