11

since it's not recommended to ignore the entire .idea folder in Android Studio most files in there are tracked by git. The strange thing however is that, after every launch, the same line is added to vcs.xml even if there are already dozens of them.

<mapping directory="$PROJECT_DIR$" vcs="Git" />

This gets old pretty quickly.

Is there a purpose for this behaviour or is it simply a bug? Further can Android Studio be prevented from doing such modifications when it is launched?

Thanks in advance.

Edit: Also ./idea/misc.xml constantly changes between JDK_1_7 and JDK_1_8.

qantik
  • 1,067
  • 1
  • 10
  • 20

1 Answers1

11

I highly recommend you to read this StackOverflow post: What should be in my .gitignore for an Android Studio project? as you would find here explanation which files should be ommitted on git push.

Personally, I don't commit ./idea/misc.xml and vcs.xml. I added them to .gitignore file. I'm using for this purpose template taken from: https://github.com/github/gitignore/blob/master/Android.gitignore

Hope it will help

Community
  • 1
  • 1
piotrek1543
  • 19,130
  • 7
  • 81
  • 94
  • Thanks, I actually use the same .gitignore template. I was just wondering why Android Studio keeps changing those files. :-) – qantik Sep 01 '16 at 18:46
  • like you said that's just IntelliJ IDEA configuration files. Already all of them may be omitted, as it would be reacreated during build task. – piotrek1543 Sep 01 '16 at 18:49