Skip to content

Instantly share code, notes, and snippets.

@martinlippert
Created March 13, 2013 19:12
Show Gist options
  • Star 10 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save martinlippert/5155155 to your computer and use it in GitHub Desktop.
Save martinlippert/5155155 to your computer and use it in GitHub Desktop.
A simple script to batch install a bunch of additional features into an existing Eclipse or STS installation. Customize to your needs in the "installFeatures()" part. First parameter there is list of feature IDs, second is the list of update sites to install those features from. Run this via: ./install-addons.sh <relative-path-to-your-sts/eclips…
#!/bin/bash
#set -x
doInstall() {
ECLIPSELOCATION=`ls $LOCATION/plugins/org.eclipse.equinox.launcher_*`
$JAVA_HOME/bin/java -jar $ECLIPSELOCATION -nosplash -application org.eclipse.equinox.p2.director \
-metadataRepository "$2" \
-artifactRepository "$2" \
-destination $LOCATION \
-installIU "$1"
}
installFeatures() {
doInstall "org.cloudfoundry.ide.eclipse.server.feature.group,\
net.sourceforge.pmd.eclipse.feature.group,\
com.yourkit.profiler.feature.group,\
org.eclipse.swtbot.forms.feature.group,\
org.eclipse.swtbot.eclipse.feature.group,\
org.eclipse.swtbot.eclipse.gef.feature.group,\
org.eclipse.swtbot.feature.group,\
org.eclipse.swtbot.ide.feature.group,\
org.eclipse.swtbot.eclipse.test.junit3.feature.group,\
org.eclipse.swtbot.eclipse.test.junit4.feature.group" \
"http://download.eclipse.org/eclipse/updates/3.8/,\
http://download.eclipse.org/releases/juno/,\
http://pmd.sourceforge.net/eclipse/,\
http://dist.springsource.com/release/TOOLS/cloudfoundry,\
http://www.yourkit.com/download/yourkit12_for_eclipse/,\
http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site"
}
export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.7.0_17.jdk/Contents/Home
export COPYFILE_DISABLE=true
cd $1
LOCATION=`pwd`
installFeatures
@ascheman
Copy link

This looks promising, but is there a similar possibility to find the local installations and their repositories also? I usually install a lot of plugins over time via the marketplace but can hardly remember anything after a while ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment