I am trying to create a new project from existing source code. I keep getting the following error: "Invalid Project Description", project path "overlaps the location of another project" with the same name. The reason is that I created that project from the source code before, but then I deleted that project and deleted its whole directory, before adding the source code directory again. I tried everything like cleaning and restarting, but nothing worked. I looked in my workspace directory, but there are no traces for the old project. There are several questions around this problem such as this Attempting Android Notepad Tutorial - Exercise 1 - More problems, but none of the answers worked for me!


当前回答

我摆脱了我的问题通过改变文件>工作空间,然后,重新启动后,重新设置工作空间。

其他回答

这个选项解决了我的问题。

链接:http://fledglingsnook.wordpress.com/2012/08/09/eclipse-issue-overlaps-the-location-of-another-project/

以下是我做的非常有效的方法。我只是在通用下导入了一个现有的项目,而不是导入一个android项目。

这个问题也快把我逼疯了,但我知道原因是什么。问题是eclipse不够聪明,不能在自定义的工作空间文件夹中创建与项目同名的文件夹。

解决这个问题的方法是确保你所有的项目都在一个与你的项目名称匹配的文件夹中,否则它会直接将你所有的项目文件转储到这个目录中。您最终看到这个错误的原因是因为它认为您正在将一个项目放在另一个项目中(可能读取了项目配置文件)。

I noticed this is especially a problem when not using the default workspace path. The way I solve this problem is to just add the Project Name to the end of location. So let's say you are putting a project named "HelloWorld" into /Users/name/Documents/projects/android/, you would want to manually add "HelloWorld" to the end of it, like this: /Users/name/Documents/projects/android/HelloWorld. This would ensure that the project is put in it's own folder called "HelloWorld" and not inside some other project. Be sure that if there are any projects not within folders into a folder of the same name as the project to solve the errors.

有各种各样的场景,但在我的例子中,我想保留文件夹及其内容,因为它已经从.git中签出。但是,我需要能够使用Eclipse修改源代码和其他内容。

我发现问题是.cproject和.project文件的路径信息非常特定于环境(与我的环境不匹配)。

我所做的是:

创建了一个新的空文件夹(名称不同),并创建了一个新的 指向该文件夹的工作区。 签出或复制。git项目/文件夹到空文件夹中。 然后导入工作区中的“常规”“现有项目”。

关键似乎是用不同的名称创建顶层的空白工作空间。

我希望这能帮助到一些人。

转到项目的。project文件,确保它显示的名称与项目文件夹中显示的名称相同。如果不是,请更改名称。它会起作用的。