A common problem we have in our git directories are files that are generated automatically. You can do a simple thing to prep for things by creating a .gitignore file in the root of your git directory. For example here is one of mine:
In this example I do a couple things.
- ignore the file generated.conf that gets created nightly by a script.
- ignore all files that end with .swp. This is useful just in case I’m using VI on a file somewhere in the directory.
- ignore the folder named RCS. There’s some legacy still here ;).
There you go! Enjoy ignoring those files. Check out the untrack files in git post I made awhile ago.