dotfiles/zsh/.oh-my-zsh/plugins/gitignore/gitignore.plugin.zsh
2024-06-19 00:06:56 +02:00

12 lines
322 B
Bash

function gi() { curl -fLw '\n' https://www.toptal.com/developers/gitignore/api/"${(j:,:)@}" }
_gitignoreio_get_command_list() {
curl -sfL https://www.toptal.com/developers/gitignore/api/list | tr "," "\n"
}
_gitignoreio () {
compset -P '*,'
compadd -S '' `_gitignoreio_get_command_list`
}
compdef _gitignoreio gi