Skip to content

Instantly share code, notes, and snippets.

@mayoralito
Created October 5, 2013 17:06
Show Gist options
  • Save mayoralito/6843458 to your computer and use it in GitHub Desktop.
Save mayoralito/6843458 to your computer and use it in GitHub Desktop.
Git is really good at keeping a perfect history of the changes to your files. That's a great quality to have when those files are code, but not so great when a bit of application configuration slips in.
We need to create a global .gitignore in our home.
```
$> touch ~/.gitignore
$> git config --global core.excludesfile ~/.gitignore
```
After that we need to open (your) editor
```
$> vim ~/.gitignore
```
and add at least the next lines (add as many as you need):
```
# Mac OS X hidden files
.DS_Store
# Vim swap files
.*.sw?
# Pow and Powder config
/.pow*
# RVM and rbenv
/.rvmrc
/.rbenv-version
# Bundler binstubs
/bin/
```
All Credits: http://devoh.com/blog/2013/01/global-gitignore
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment