Tuesday, January 03, 2006

Using RadRails and Subversion

Download and install Radrails.
Download and install Subversion (directions for Windows XP)

Click -> Window -> Open Perspective -> Other -> Rails
This will open the Navigotor view, along with Servers, Generators, Console and Regular Expressions views

In RadRails, click File -> New -> Rails -> Rails Project
Specify demo as the Project name and click Finish.

Click Window-> Show View -> SVN Repository
Right click -> New -> Repository location
When prompted, enter Repository location information. For Url, enter svn://
For Root, select svn://
Select Validate Connection on Finish
Click Finish
It should connect to your subversion respository and show in the SVN Repository window.

Select this repository.
Right click -> New -> New remote folder
Specify demo in the Folder name , add a comment and click on Finish.

Note: I created the demo directory in the repository first since I would like to check in my code into a subfolder called "trunk" of this directory.

Now we will add our code to the repository.

In the Navigator pane, test will appear. Right click -> Team -> Share Project -> SVN
Select "Use existing repository location" and click Next.
Click on "Use specified folder name" -> Browse, select "demo" -> replace "New Folder" with "trunk" and click on Next.
Finish.

It will prompt you with the SVN commit dialog
Click on Select All and add a comment and then click "Ok"

Now you can use the Right click menu in the Navigator pane and do various revision control operations.


Some tips on using RadRails

Make sure you are using Rails perspective.

If you need to check out a new copy of the demo project, click Window -> Show View -> SVN Repository.
Right click on the "demo" folder -> Check Out As -> Rails Project.
Click Next and specify a project name and click Finish.

Update: I found some info about using rails with subversion.