PhpStorm global GIT ignore steps

Steps to exclude .idea folder globally in phpstorm:
Create this file:
C:\Users\Bas\gitignore_global.txt

Add this contents:

1
2
3
4
5
6
7
8
9
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
.idea
.idea/*

Now in phpstorm open the terminal panel (command line shell) and type:

1
git config --global core.excludesfile c:\Users\Bas\gitignore_global.txt

Next restart phpstorm. Now if you clone a new project it will never bother you about the .idea folder.