conf2/zsh/.oh-my-zsh/plugins/gitignore/gitignore.plugin.zsh

13 lines
284 B
Bash
Raw Normal View History

2020-06-11 14:41:32 +00:00
function gi() { curl -fLw '\n' https://www.gitignore.io/api/"${(j:,:)@}" }
2019-01-12 15:47:23 +00:00
_gitignoreio_get_command_list() {
curl -sfL https://www.gitignore.io/api/list | tr "," "\n"
}
_gitignoreio () {
compset -P '*,'
compadd -S '' `_gitignoreio_get_command_list`
}
compdef _gitignoreio gi