


This is useful for a variety of reasons, some of which may be the following: Git will ignore files that match the rules within the file by default. You can place a gitignore file into the root directory of your repository. Trashes ehthumbs.db Thumbs.db # Vagrant stuff. This is an example of my current gitignore file that I am using at the time of writing this post: # Compiled source # *.com *.class *.dll *.exe *.o *.so # Packages # it’s better to unpack these files and commit the raw source # git has its own built in compression methods *.7z *.dmg *.gz *.iso *.jar *.rar *.tar *.zip # Logs and databases # *.log *.sql *.sqlite # OS generated files #. You can find common git ignore files online via google and other resources. Using wildcards like the ones above allow you to exclude every file of a particular type, based on file extension. Wildcards also work: # Using wildcards *.extension *.zip *.sql The contents of the file are structured like so: # The character '#' is used to denote comments name-of-file.extension This can be done at the repository level or the global level.

You can create a configuration file that is used to ignore these files. This is going to be a short how-to for removing those files from your repository (but they will still stay intact on your local system). Have you ever run into an issue where you have files in your Git repository that should not be there? Examples could be full databases, log files, compiled binaries, vagrant directories, virtual machines, jar files, OS generated files like thumbnails, archives, and so on.
