Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Jetty/Contributor/DevelopingWithGit


Obtaining code via GIT

Jetty has it's source control on dev.eclipse.org, which is accessible via 2 different urls.

Choose your access technique and follow along ...

To start, you'll want to make sure you have git-svn installed. You can do that by checking if there is help for you.

git svn --help

Next, you'll want to use the git-svn to clone the subversion tree to your local disk. However, the command line is a bit long, so I created a helper bash script to make this task a bit easier.

#!/bin/bash
JETTYSVNROOT=http://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty
git svn clone -r HEAD \
 --branches $JETTYSVNROOT/branches \
 --tags $JETTYSVNROOT/tags \
 --trunk $JETTYSVNROOT/trunk \
 $JETTYSVNROOT

That will pull the jetty tree from subversion, from the HEAD revision, via git-svn, to you local disk as a directory called "jetty"

Once this step is done, you now have the codebase in git format to work with.

Recommended Eclipse Plugins

Maven Integration - m2eclipse Update Site: http://m2eclipse.sonatype.org/update

GIT Team Provider - jgit Update Site: http://www.jgit.org/updates

Import into Eclipse

Tip: build the checked out codebase on the command line to make the various dependencies available for use eclipse. See Building for details. (This is likely to improve in the future with more m2eclipse plugin releases)

To import Jetty into Eclipse do the following ...

  1. Start Eclipse
  2. Ensure above Recommended Eclipse Plugins are installed.
  3. Open the "Import Maven Projects" dialog by going to File > Import ... > General > Maven Projects
  4. Browse to the 'git-svn' cloned directory for Jetty and import all projects.

GIT From a Subversion Users Point of View

Git, like subversion, is at home on the command line. However, unlike subversion, git can operate entirely without network access.

When you modify files and commit them, you are only commiting them to the local Git repository that you have recently checked out. Those changes do not exist outside of your own personal git repository.

The Git - SVN Crash Course is a good references for those familiar with subversion, but are new to git. The crash course gives a comparison of popular Subversion commands and what their Git equivalents are.

Back to the top