How do I check out an SVN project into Eclipse as a Java project?


Answers

Here are the steps:

  • Install the subclipse plugin (provides svn connectivity in eclipse) and connect to the repository. Instructions here: http://subclipse.tigris.org/install.html
  • Go to File->New->Other->Under the SVN category, select Checkout Projects from SVN.
  • Select your project's root folder and select checkout as a project in the workspace.

It seems you are checking the .project file into the source repository. I would suggest not checking in the .project file so users can have their own version of the file. Also, if you use the subclipse plugin it allows you to check out and configure a source folder as a java project. This process creates the correct .project for you(with the java nature),

Question

I was trying to check out a project from SVN using Eclipse. I tried using "Checkout As" to make it into a "Java project from existing Ant script", but the project wizard requires the file to have already been downloaded. Is there a way to checkout the project into Eclipse as a Java project, without having to download it elsewhere first?

(I am using Eclipse Ganymade 3.4.1 with Subversive.)




You can do it directrly from Eclipse if you install Subclipse or Subversive plugin. Then you can either reimpoort your project into workspace or use Team -> Share option in context menu (right-click) of the project.




How to Open an Existing SVN Project in Eclipse

Note

  • You'll find the commands for SVN under the Team sub-menu when you right click on your project.

  • I've had trouble in the past when connecting to SVN repositories using the svn+ssh:// protocol - a quick fix is to change the SVN interface (under Window > Preferences > Team > SVN) to the pure Java option (SVNKit IIRC).









Links



Tags