How to remove .idea folder from Your Repository

If You start new project, some tools create more folders and files. How to take off the garbage after a quick and automatic commit and push from intellij?

  • Add .idea directory to the list of ignored files
echo '.idea' >> .gitignore
  • Remove the directory only from the repository
git rm -r --cached .idea
  • Send the change forward
git add .gitignore
git commit -m 'untracking .idea'
git push origin master
Tom Sapletta
Facebooktwitterredditpinterestlinkedinmail

Author: Tom Sapletta

I connect the expiriences with new ideas. I have been passionate about computers and programming for 10 years. My first (micro) computer was ZX-Spectrum and the programming language was Basic. Since 2010, I have been programming professionally, objectively and functionally in monolithic and micro-service architectures. I am currently creating an ecosystem architecture at API foundation.