How to convert IntelliJ project to Eclipse?

2019-02-07 23:52发布

I have one IntelliJ project and I want to open it in Eclipse, so what should I do?

3条回答
放我归山
2楼-- · 2019-02-08 00:01

Without access to IntelliJ to export and convert the project, try the following.

In STS or Eclipse create an empty project first, then, select File -> Import and choose General -> File System. In the resulting dialog box, select the root folder of the IntelliJ project as source and the empty project as the destination.

For unit tests, add the test folder as a source folder to the build path (right-click on the folder, select Build Path -> Use as Source Folder).

The projects I import this way run without any further modifications, including the tests.

查看更多
三岁会撩人
3楼-- · 2019-02-08 00:08

There is an export to eclipse option in Intellij Under file menu.

This option will generate you the necessary .project and .classpath files that will be used by eclipse. Personally, I would remove any IDE dependencies using some dependency management systems like Maven or Apache IVY. ( Is system the right term?)

查看更多
时光不老,我们不散
4楼-- · 2019-02-08 00:21

I had the same issue and (I don't have Intellij) but doc_180's comment pointed me in the right direction. Here is a simple solution. In Eclipse create a new blank Android project. Copy the .project and .classpath files and the .settings folder to the Intellij folder. Edit the .project file and change the name of the project.

You should now be able to Import the project in Eclipse by right clicking and selecting "Import->Existing Project into Workspace".

I see this is an old question, but thought I should add this answer for others Googling it like me ;)

查看更多
登录 后发表回答