diff options
author | Marvin Borner | 2019-03-05 01:09:01 +0100 |
---|---|---|
committer | Marvin Borner | 2019-03-05 01:09:01 +0100 |
commit | 55457187d18221e76bd12f0fb2cfab65c49b92fb (patch) | |
tree | 8db042d2d80710d54100c2709ad4332153ac848a /.oh-my-zsh/plugins/heroku |
Initial commit
Diffstat (limited to '.oh-my-zsh/plugins/heroku')
-rw-r--r-- | .oh-my-zsh/plugins/heroku/README.md | 9 | ||||
-rw-r--r-- | .oh-my-zsh/plugins/heroku/heroku.plugin.zsh | 9 |
2 files changed, 18 insertions, 0 deletions
diff --git a/.oh-my-zsh/plugins/heroku/README.md b/.oh-my-zsh/plugins/heroku/README.md new file mode 100644 index 0000000..2bf92c9 --- /dev/null +++ b/.oh-my-zsh/plugins/heroku/README.md @@ -0,0 +1,9 @@ +# Heroku + +This plugin provides completion for the [Heroku CLI](https://devcenter.heroku.com/articles/heroku-cli). + +To use it add heroku to the plugins array in your zshrc file: + +```bash +plugins=(... heroku) +``` diff --git a/.oh-my-zsh/plugins/heroku/heroku.plugin.zsh b/.oh-my-zsh/plugins/heroku/heroku.plugin.zsh new file mode 100644 index 0000000..9a99b42 --- /dev/null +++ b/.oh-my-zsh/plugins/heroku/heroku.plugin.zsh @@ -0,0 +1,9 @@ +HEROKU_AC_CACHE_DIR="$HOME/.cache" +if [ "$(uname -s)" = "Darwin" ]; then + HEROKU_AC_CACHE_DIR="$HOME/Library/Caches" +fi +if [ ! -z "$XDG_CACHE_HOME" ]; then + HEROKU_AC_CACHE_DIR="$XDG_CACHE_DIR" +fi +HEROKU_AC_ZSH_SETUP_PATH=$HEROKU_AC_CACHE_DIR/heroku/autocomplete/zsh_setup +[ -f $HEROKU_AC_ZSH_SETUP_PATH ] && source $HEROKU_AC_ZSH_SETUP_PATH |