1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-11-30 01:30:08 +00:00
ohmyzsh/plugins/gitignore/gitignore.plugin.zsh
Marc Cornellà b452cafb16 Follow-redirect and silent mode curl throughout gitignore
This commit completes previous efforts and standardizes both curl commands
into using silent mode and following redirects in case the URL changes
again in the future.
2014-10-22 18:13:15 +02:00

12 lines
268 B
Bash

function gi() { curl -sL https://www.gitignore.io/api/$@ ;}
_gitignoreio_get_command_list() {
curl -sL https://www.gitignore.io/api/list | tr "," "\n"
}
_gitignoreio () {
compset -P '*,'
compadd -S '' `_gitignoreio_get_command_list`
}
compdef _gitignoreio gi