Import a module from one .idea project into another

I have two projects, both of which use .idea directory format.  I need to import a module from one project into another.  However, with the .idea project format, I can't find the .iml files for the module.

I used a "Copy Module" but that didn't work either - I didn't find the .iml file, and even if I did, it looked like the module wasn't copied - the facets and dependencies and other setup information weren't in the new "copy". (Or maybe I just copied it incorrectly).

Does anyone know how I can best proceed?


Comment actions Permalink

The .iml files are not in the .idea folder. They are where you specify them to be. Usually they are in the content root of the module. If you are unsure and don't want to search for *.iml you can also look at .idea/modules.xml, there the paths are stored.

Comment actions Permalink

Ahh, thanks! I found my .iml file. I don't know why it's where it is, though.  It's in the Java src directory instead of the directory where I want all my IDE files to be.  I must've missed that during the project setup.



Please sign in to leave a comment.