How to make an existing directory into an eclipse project

I have a project I am working on. I have decided to try working with it in Eclipse. There is already a directory, under version control where all the code resides. I am having a rather strange problem. I cannot find any way to just start using an existing code directory as an eclipse project. All I can find is how to import existing source into a new project or check out source from version control into a new project. How do I make an existing directory into a project?

My project is a Django web app if it is any help


Solution 1:

In the New Java Project wizard, uncheck the checkbox that says Use default location and the use the Browse button to find your directory.

Solution 2:

It is pretty easy to do. Go to File->New-> Project. In the Project wizard, choose the type of project you want and then be sure to unclick the 'Use default location` checkbox. Browse for your folder in the widget that then becomes enabled. Click finish after that.

Alternatively, you could create a brand new project workspace in a new location. Then, assuming Java as your project type, you can open up your project properties and add as a source folder your existing directory. To do this, use the 'Link Source' button on the Java Build Path -> Source tab of your Project Properties dialog.

Solution 3:

My Method:

I clone this file to new project directory , and rename Project-Name to my project name, after that i import new files and directory from Eclips

File Name: .project ( Use Notepad for make this file...select Save as type to All Files (*.*) and write file name like: .project )

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
    <name>Project-Name</name>
    <comment></comment>
    <projects>
    </projects>
    <buildSpec>
    </buildSpec>
    <natures>
    </natures>
</projectDescription>

Solution 4:

Hope this link answers the original question of this thread.

http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Ftasks%2Ftasks-45.htm

Creating linked resources

Folders and files can be linked to locations in the file system outside of the project's location. These special folders and files are called linked resources.

To create a linked folder:

  1. In one of the navigation views, right-click the project or folder where you want to create the linked folder.

  2. From the pop-up menu, select command link New > Folder.

  3. Specify the name of the folder as it will appear in the workbench. This name can be different from the name of the folder in the file system.

  4. Click Advanced.

  5. Check Link to alternate location (Linked Folder).

  6. Enter a file system path, or click Browse to select a folder in the file system.

  7. Click Finish.