views:

2819

answers:

2

I have created my ActionScript source files in a folder on a Mac (I normally use PC), and somehow managed to make an Eclipse/FDT project that can see them.

I now need to move them into a svn checkout of an existing project to get them under source control.

I just can't work out how you do this without losing all references in the project.

I'm new to Eclipse and don't really understand any of the terminology (e.g. workspace). Does Eclipse have project files or are they all hidden? Can the project file be moved?

Help me stackoverflow, you're my only hope.

Update: From the FDT Flash Explorer window I can only seem to be able to move files/folders within projects that exist. Should I create a new project in the place I want first?

Should I move them from within Eclipse or from the file system? Do I need to setup a new workspace afterwards?

+2  A: 

Try refactoring your project. Rightclick on the folder to move and then choose Refactor->Move. Don't know if this will solve your problem but it will try to change the references in all projects according to the move.

boutta
From the FDT Flash Explorer window I can only seem to be able to move it within projects that exist. Should I create a new project in the place I want first?
Iain
You could try that, but I'm not sure of all the steps you mentioned.
boutta
+1  A: 

The project folder has 2 hidden files: .project and .classpath that have all the info of the project. You just need to copy those files along with your project files.

For instance, you have a project folder in workspace/myproject/, and you want to add it to a checkout svn folder, you just need to copy the complete folder content to the checkout and then add all the files to the svn (including the project hidden ones) and finally commit.

From now on, when you checkout from that svn, you will have the eclipse project files, so all you need to do is create new project, and select the option that says that you already have a project folder with the source files (I'm not near an eclipse IDE to tell exactly the steps, but it's something like this). Eclipse will then import the project with all the settings you had previously defined.

I hope that this answers your question.

rogeriopvl
How do I show hidden files on the Mac?
Iain
and why would it HIDE your project files?!
Iain
because those files are just for eclipse to know which files are included in your project... You can open up a terminal go to your project directory and type "ls -a" .. it will show the hidden files.
rogeriopvl
Should I move them from within Eclipse or from the file system? Do I need to setup a new workspace?
Iain
no there's no need to create a new workspace. Just make sure that the hidden files are always there, and eclipse will be able to restore your project when importing the folder.
rogeriopvl
you never said I should import the folder. I think you may have miswed out some vital steps in your answer. Bear in mind I am a total newb.
Iain
I'm going to update my post with the steps.
rogeriopvl
A problem with this approach is that you lose all general settings stored in your workspace, i.e. all Eclipse configuration settings not related to a specific project.
Blaisorblade