Skip to content

Instantly share code, notes, and snippets.

@jaspervalero
Created February 20, 2015 05:34
Show Gist options
  • Save jaspervalero/ca8ee62fdb10a50e4ec2 to your computer and use it in GitHub Desktop.
Save jaspervalero/ca8ee62fdb10a50e4ec2 to your computer and use it in GitHub Desktop.
My custom dotfile function for gitignore.io
# Generate .gitignore file from gitignore.io API
# $@ - Comma separated list of templates to use, i.e. osx,sublimetext
# Common commands:
# 'ignore list' - List all currently supported templates
# 'ignore example1,example2' - Preview output in console
# 'ignore example1,example2 >> .gitignore' - Output to .gitignore file in CWD
# 'ignore example1,example2 >> ~/.gitignore' - Output to global .gitignore
function ignore() {
curl -s https://www.gitignore.io/api/$@ ;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment