Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I get my app.iml to stay stable on Android Studio project rebuild?

The order of the orderEntry library tags in my app.iml keeps changing when I switch branches and Android Studio rebuilds my project. Is there any way to get Android Studio to generate it in a stable/deterministic way so that I don't constantly have diffs in git where a library moved up or down in the order?

Sometimes it's like this:

<orderEntry type="library" exported="" name="support-annotations-21.0.3" level="project" />
<orderEntry type="library" exported="" name="google-http-client-jackson2-1.19.0" level="project" />

Other times it's like this:

<orderEntry type="library" exported="" name="google-http-client-jackson2-1.19.0" level="project" />
<orderEntry type="library" exported="" name="support-annotations-21.0.3" level="project" />

I don't really care I just want it to stop churning.

Edit:

According to JetBrains you are supposed to share the .iml files:

http://intellij-support.jetbrains.com/entries/23393067

like image 689
kg. Avatar asked Apr 07 '15 05:04

kg.


1 Answers

You can just add this files to gitignore:

*.iml
like image 160
x90 Avatar answered Oct 13 '22 07:10

x90