Reputation: 229998
I'm working with Maven pom files, and I don't wish to source control iml files. When I open a project, IntelliJ seems to add some of the iml files it creates to the SVN source control. How can I prevent this?
I have "*.iml" in an "svn:ignore" property on the repository root, but it doesn't seem to prevent IntelliJ from adding the imls.
Upvotes: 33
Views: 42287
Reputation: 2707
If you want to disable checking in *.iml files across all projects, on the Mac OS X 10.8.x you can go to IntelliJ -> Preferences (Command-,) -> Version Control -> Ignore Files and set it up there. This is better if you are like me who works on many projects and frequently need to create/import new projects, I don't want to have to setup this pref on every individual project.
Upvotes: 2
Reputation: 1
In case somebody else stumbles onto this issue, the best luck I've had is
Settings > Version Control > Ignored Files
Add "Ignore all Files Matching"s for:
*.idea
*.iml
Not sure which version of IDEA rolled out this functionality, and this question is somewhat old, so it may be moot. Just hope it helps somebody else out who landed here from Google as I did.
Upvotes: 34
Reputation: 11855
Elaborating on Colin Hebert answer. Yes, it is possible to move the iml file to another directory when importing from Maven. And this seem to be the only way to prevent this problem.
Here the settings to use in import:
Since all important informations are keep in Maven itself it only takes a little time to reimport an existing modules. The gain truly is worth it.
Upvotes: 3
Reputation: 93157
You can also choose to not have your .iml file in a versionned directory.
When you create the module, you can select the module file location.
Here my iml file will be in /ModuleName.iml but the content will by in /myRoot/
Upvotes: 2
Reputation: 191
The latest version of IntelliJ Community prompts you for the iml file additions separately. If you check the box to avoid being warned in future and choose "no" the first time you are prompted, it will not schedule any further IML files for addition to subversion.
Upvotes: 8
Reputation: 9532
Configure IntelliJ to not add files automatically to subversion.
In IntelliJ 6, this configuration is on Settings > Version Control > General Settings:
File Creation/Deletion
When files are created with IDEA:
[x] Show options before adding to version control
Upvotes: -1