mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-15 01:48:34 -07:00
feat(zoxide): add option to override cmd (#12218)
This commit is contained in:
parent
872b5cd408
commit
15ffbdd346
@ -10,5 +10,8 @@ To use it, add `zoxide` to the plugins array in your `.zshrc` file:
|
||||
```zsh
|
||||
plugins=(... zoxide)
|
||||
```
|
||||
## Overriding `z` Alias
|
||||
|
||||
You can set the `ZOXIDE_CMD_OVERRIDE`, which will be passed to the `--cmd` flag of `zoxide init`. This allows you to set your `z` command to a default of `cd`.
|
||||
|
||||
**Note:** you have to [install zoxide](https://github.com/ajeetdsouza/zoxide#step-1-install-zoxide) first.
|
||||
|
@ -1,5 +1,5 @@
|
||||
if (( $+commands[zoxide] )); then
|
||||
eval "$(zoxide init zsh)"
|
||||
eval "$(zoxide init --cmd ${ZOXIDE_CMD_OVERRIDE:-z} zsh)"
|
||||
else
|
||||
echo '[oh-my-zsh] zoxide not found, please install it from https://github.com/ajeetdsouza/zoxide'
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user