Skip to content

Instantly share code, notes, and snippets.

@ZacBlanco
Last active July 15, 2016 18:32
Show Gist options
  • Save ZacBlanco/1dcbba068ee2266114e6526897e33ca6 to your computer and use it in GitHub Desktop.
Save ZacBlanco/1dcbba068ee2266114e6526897e33ca6 to your computer and use it in GitHub Desktop.
Install the TKP Components with a Single Bash script on OS X
mkdir ~/Documents/TKPSource
cd ~/Documents/TKPSource
LOC=$(system_profiler SPApplicationsDataType | grep Eclipse.app | grep -o '\/.*.app')
echo "LOCATION: $LOC"
if ! [ -a $LOC ]; then
echo "=============================================="
echo "DOWNLOADING ECLIPSE"
echo "=============================================="
curl -L http://mirror.cc.columbia.edu/pub/software/eclipse/technology/epp/downloads/release/luna/SR2/eclipse-java-luna-SR2-macosx-cocoa-x86_64.tar.gz -o eclipse-luna.tar.gz
echo "=============================================="
echo "EXTRACTING ARCHIVE"
echo "=============================================="
tar -xf eclipse-luna.tar.gz
cp -r eclipse/Eclipse.app/ ~/Applications/
fi
LOC2=$(which javac)
if ! [ -a $LOC2 ]; then
curl -L http://download.oracle.com/otn-pub/java/jdk/8u91-b14/jdk-8u91-macosx-x64.dmg?AuthParam=1468602815_c8dd984cb06900d3ccde409928aa6dbd -o jdk.dmg
hdiutil attach jdk.dmg
echo "=============================================="
echo "Please open JDK 8 Update 91 on your Desktop and install the .pkg"
echo "Press Enter to Continue..............."
echo "=============================================="
read stuff
fi
curl -L -O https://github.com/TeachingKidsProgramming/TeachingKidsProgramming.Java/archive/master.zip
unzip master
cd TeachingKidsProgramming.Java-master
java -jar TKP_Launcher.jar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment