Aleksandar Stefanović
Aleksandar Stefanović

Reputation: 1593

Android Studio doesn't ignore .gitignore files

I've added some masks and files to gitignore by Settings>Version Control>Ignored Files:

enter image description here

However, when I try to submit a new commit, those files are not ignored:

enter image description here

And I'm not sure why... I remember using "Ignored Files" before (in the same manner), and it worked correctly. Can anyone what's happening here?

Upvotes: 4

Views: 1676

Answers (1)

yole
yole

Reputation: 97178

First of all, Settings | Version Control | Ignored Files is not .gitignore, it's IntelliJ IDEA's own ignore mechanism, which works for any version control system.

This mechanism only works for ignoring unversioned files. If you have already added your .iml file to the version control, it will not ignore subsequent changes to that file.

Upvotes: 1

Related Questions