Module exclude folders coming and going when running maven


We have a project which are syncronised with maven pom files.
We also are sharing our project files (.idea style) in our VCS.

Every now and then our iml-files for the modules are changed:
Different excludes are appearing or disappearing:
<excludeFolder url="file://$MODULE_DIR$/target/test-classes" />
<excludeFolder url="file://$MODULE_DIR$/target/surefire-reports" />

As far as I know this is changing whenever we do mvn clean or mvn test. After a mvn clean they disappear and after a test-run or install they appear.
This is very annoying for us. Is there a better way maybe to setup our project to avoid this?

Please sign in to leave a comment.