diff --git a/init.fish b/init.fish index 2e9cc17..52b8439 100644 --- a/init.fish +++ b/init.fish @@ -1 +1,5 @@ -zoxide init fish | source +if command -sq zoxide + zoxide init fish | source +else + echo 'zoxide: command not found, please install it from https://github.com/ajeetdsouza/zoxide' +end diff --git a/zoxide.plugin.zsh b/zoxide.plugin.zsh index 2acda37..aa89a44 100644 --- a/zoxide.plugin.zsh +++ b/zoxide.plugin.zsh @@ -1 +1,5 @@ -eval "$(zoxide init zsh)" +if (( $+commands[zoxide] )); then + eval "$(zoxide init zsh)" +else + echo 'zoxide: command not found, please install it from https://github.com/ajeetdsouza/zoxide' +fi