diff options
Diffstat (limited to 'plugins/gitignore/gitignore.plugin.zsh')
-rw-r--r-- | plugins/gitignore/gitignore.plugin.zsh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/plugins/gitignore/gitignore.plugin.zsh b/plugins/gitignore/gitignore.plugin.zsh new file mode 100644 index 000000000..332497cec --- /dev/null +++ b/plugins/gitignore/gitignore.plugin.zsh @@ -0,0 +1,12 @@ +function gi() { curl http://gitignore.io/api/$@ ;} + +_gitignireio_get_command_list() { + curl -s http://gitignore.io/api/list | tr "," "\n" +} + +_gitignireio () { + compset -P '*,' + compadd -S '' `_gitignireio_get_command_list` +} + +compdef _gitignireio gi
\ No newline at end of file |