This document shows how to checkout Force.com metadata from a Subversion source code control system. After establishing a few prerequisites, we show how to install Subclipse, the Eclipse Subversion plug-in, and then how to check code out from a repository.
Before proceeding, please note that these instructions assume you have the Force.com IDE installed and are familiar with the basic functionality of Eclipse. If not, take some time to become familiar with both before proceeding to check-out any source code.
In addition, these steps require that you have installed the Eclipse plug-in that adds support for Subversion revision control system, also known as SVN. Because this is an important feature, please install the subclipse add-in and become familiar with the documentation it provides. If you have used SVN in the past, you may be able to install the subclipse add-in and proceed with the following steps.
Follow the instructions here: http://subclipse.tigris.org/install.html
- Be sure to uncheck Integrations containing Buckminster and Subclipse Integration for Mylyn during the plugin installation.
- If this is the first time you have used SVN, please read the supporting documentation that comes with the Subclipse add-in.
Locating the Repository and Checking out the source code
Steps to Checkout
- In the IDE, create a Force.com project for your new Developer Edition org.
- Choose the SVN Repository Exploring perspective in the upper right-hand corner.
- If this is not available, go to the Window menu, select "Open Perspective", choose "Other", then from the menu that appears, select "SVN Repository Exploring".
- Right-click in the SVN Repository Explorer and select New -> Repository Location.
- Specify the URL of your repository. (In this example, we're using the url of the Force.com for Facebook Toolkit)
- Click Finish.
- Expand the SVN repository until you see your project folder. (In this case it's the "ForceToolkit4FB" folder.)
- Right-click on the src folder and choose Export.
- For the export directory, click the Browse button and navigate to your project in the file system. (Select the project directory in this step, and not the src sub-directory.)
- Click 'Ok'.
- Use the pull-down menu in the upper right-hand corner of Eclipse to switch to the Force.com perspective.
- If this is not available, go to the "Window" menu, select "Open Perspective", choose "Other", from the menu that appears, select "Force.com".
- Right click the src folder in your project and select Refresh. This will update your workspace with the files retrieved from SVN.
- Right click the src folder again, and select Force.com > Save to Server. This will update Force.com with the files retrieved from SVN.
- Verify that your project builds without error.