I'm currently using BitBucket for my repos with the git engine. I'm not using github since is a private project, so I can't set it public.
When I create my .gitignore
file with gitignore.io, trying to ignore PhpStorm and WebStorm, Gitkraken (which is my git client on Mac) it isn't ignoring the .idea
folder. And each time I change my workspace layout opening or closing a sidebar or a file, then git is tracking that change. I can't figure out what's wrong, since I've also tried to set .idea/
in .gitignore
, but the files inside it are still tracked...
Any ideas?
update your .gitignore file. for instance, add one more folder for those you want to untrack in .gitignore: foldername.
To stop tracking a file you need to remove it from the index. This can be achieved with this command.
git rm --cached . remove all tracked files, including wanted and unwanted.
then
git add . all files will be added to track, exclude those in .gitignore.
How @ElplieKay said, the file once is tracked it can't be ignored anymore. Unless you remove it from git.
Another solution is to remove the file or folder (using -r) from the shell. So on the next commit it will be ignored.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With