Archive for the ‘Subversion’ Category

FDT – SVN: connecting your project to a repository

Wednesday, February 10th, 2010

Now I am just new to all this, yet been through the process enough to see that there are a few things here and there that appear a bit complicated whilst trying to achieve hooking up your project to SVN reposis. Here is my list, step-by-step, I hope it will help some of you.

Original setup: FDT 3 on macbook pro, snow leopard, with a CVSDude/Codesion account.

CVSDude/Codesion:

- set up an account for our project. there is plenty of discussion on having multiple projects per repository, I so far tend to separate them to have a single on for each project.

- add the subversion service (New)

- add a user or group with the appropriate privileges to the project under the ‘People’ section. If you are the admin of your subversion account, your name will already be added as default.

- copy the URL in the service list under Project Quickview next to Subversion

FDT

- in FDT go to the View/Perspective icon (top right) and if not already in the list, click on Other… and choose the SVN Repository Exploring perspective

- go to the window on the SVN Repositories window and right-click to add a New repository location

- paste your project Subversion URL into the URL field, enter your username and password in Authentication, click finish.

Now for some reason, sometimes the pasting adds the URL twice in two lines and you will receive an error. Just repeat the process above, choose the faulty URL from the dropdown this time and delete the additional URL from the textfield and connect again, it should let you in this time.

- add a ‘trunk’ and ‘tags’ folder to your repository, they will automatically recognized as special folders

- Go to the Flash FDT perspective

- create a Flash project

- Go to Team >Share Project

- Choose the project repository you ant to use for this project

- On the Specify Location screen in Simple Mode browse to the repository’s trunk to choose as location

- Finish

- On the first commit screen, tick off all files, that you don’t want to version control. E.g. for simplicity reasons, don’t commit anything with a ‘.’ in it’s name (e.g.  .settings).

- After this first commit, go to all your files and folders that you want to snv:ignore for the future. Right-click > Team > Add to svn:ignore   Most likely all not-dealt-with files will have a small question mark on them. After you set them to ignore, it will dissappear.

- Add a ‘lib’ folder to your flash project structure, it’s the place I put my swc’s. Right-click >Source Folder>Add to ClassPath  and it will show the appropriate icon.

- commit the ‘lib’ folder by right-click>Team>Commit

- to finalize, Team>Update the whole flash project

- Now you can add other flash files by dragging them onto your src or lib folder and dont forget you Main.as, which I tend to place outside the src folder by creating a new class file and copy pasting or writing whatever needs to go in there. Most other existing class files can be added by drag drop on ‘src’

- Done

Hope that helped.

!!! Important: if you like to drag and drop your code files into a new flash project and youhave been using them in another subversed project be careful! SVN puts little hidden svn files in every folder. Use TinkerTool or something similar to show hidden files on your system and clean all those up otherwise they will mess with the SVN.