Skip to content

Instantly share code, notes, and snippets.

@haixuanc
Created April 15, 2015 17:51
Show Gist options
  • Save haixuanc/7eece5f417641fb162e4 to your computer and use it in GitHub Desktop.
Save haixuanc/7eece5f417641fb162e4 to your computer and use it in GitHub Desktop.
A global .gitignore
# Run the following command in terminal to use it:
# $ git config --global core.excludesfile ~/.gitignore_global
# Reference: https://help.github.com/articles/ignoring-files/
# 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 #
######################
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
# Vim #
#######
[._]*.s[a-w][a-z]
[._]s[a-w][a-z]
*.un~
Session.vim
.netrwhist
*~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment