Skip to content

Instantly share code, notes, and snippets.

@ccopsey
Created March 28, 2011 16:30
Show Gist options
  • Select an option

  • Save ccopsey/890780 to your computer and use it in GitHub Desktop.

Select an option

Save ccopsey/890780 to your computer and use it in GitHub Desktop.
Eclipse UpdateSite Mirroring and Batch Install
function execute {
echo $@
$@
echo
}
arch="linux-gtk-x86_64"
date=`date +%Y%m%d`
eclipseRootDirectory="/home/chris/eclipse"
eclipseDistribution="eclipse-jee-helios-SR2-$arch"
eclipseBinDirectory="$eclipseRootDirectory/$eclipseDistribution-$date"
updatesiteDirectory="/home/chris/eclipse/updatesites"
pluginsDirectory="/home/chris/eclipse/plugins"
equinoxLauncher="$eclipseBinDirectory/plugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar"
updateCmd="java -jar $equinoxLauncher -application org.eclipse.update.core.standaloneUpdate"
p2Cmd="java -jar $equinoxLauncher -application org.eclipse.equinox.p2.director"
umask 77
rm -rf ~/workspace
rm -rf ~/.eclipse
rm -rf $eclipseRootDirectory/eclipse
rm -rf $eclipseBinDirectory
tar -zxf $eclipseDistribution.tar.gz -C $eclipseRootDirectory
mv $eclipseRootDirectory/eclipse $eclipseBinDirectory
# CDT
execute "$updateCmd -command install -featureId org.eclipse.cdt -version 7.0.1.201009241320 -from file:$updatesiteDirectory/cdt_helios"
execute "$updateCmd -command install -featureId org.eclipse.photran -version 6.0.6.201102161000 -from file:$updatesiteDirectory/ptp_helios"
# Egit
execute "$updateCmd -command install -featureId org.eclipse.jgit -version 0.11.3 -from file:$updatesiteDirectory/egit"
execute "$updateCmd -command install -featureId org.eclipse.egit -version 0.11.3 -from file:$updatesiteDirectory/egit"
# Texclipse
execute "$updateCmd -command install -featureId net.sourceforge.texlipse -version 1.4.1 -from file:$updatesiteDirectory/texlipse"
# Subversion
execute "$updateCmd -command install -featureId org.tmatesoft.svnkit -version 1.2.3.5521 -from file:$updatesiteDirectory/subclipse_1.4"
execute "$updateCmd -command install -featureId org.tigris.subversion.clientadapter.feature -version 1.5.3 -from file:$updatesiteDirectory/subclipse_1.4"
execute "$updateCmd -command install -featureId org.tigris.subversion.clientadapter.javahl.feature -version 1.5.7 -from file:$updatesiteDirectory/subclipse_1.4"
execute "$updateCmd -command install -featureId org.tigris.subversion.clientadapter.svnkit.feature -version 1.5.6.1 -from file:$updatesiteDirectory/subclipse_1.4"
execute "$updateCmd -command install -featureId org.tigris.subversion.subclipse -version 1.4.8 -from file:$updatesiteDirectory/subclipse_1.4"
execute "$updateCmd -command install -featureId org.tigris.subversion.subclipse.graph.feature -version 1.0.7 -from file:$updatesiteDirectory/subclipse_1.4"
# Google
execute "$updateCmd -command install -featureId com.google.gdt.eclipse.suite.e36.feature -version 1.4.2.v201012211742 -from file:$updatesiteDirectory/google_3.6"
execute "$updateCmd -command install -featureId com.google.appengine.eclipse.sdkbundle.e36.feature.1.4.0 -version 1.4.0.v201012021502 -from file:$updatesiteDirectory/google_3.6"
execute "$updateCmd -command install -featureId com.google.gwt.eclipse.sdkbundle.e36.feature.2.1.1 -version 2.1.1.v201012170127 -from file:$updatesiteDirectory/google_3.6"
# PyDev
execute "$updateCmd -command install -featureId org.python.pydev.feature -version 1.6.5.2011020317 -from file:$updatesiteDirectory/pydev"
# PHPEclipse
execute "$updateCmd -command install -featureId net.sourceforge.phpeclipse.feature -version 1.2.3.200910091456PRD -from file:$updatesiteDirectory/phpeclipse_1.2"
# SQLExplorer
execute "$updateCmd -command install -featureId net.sourceforge.sqlexplorer -version 3.6.1.v20110108_SR1 -from file:$updatesiteDirectory/eclipsesql"
execute "cp -R $pluginsDirectory/shelled_1_0_4/* $eclipseBinDirectory/dropins/"
cp install.sh $eclipseBinDirectory/
echo "Done."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment