Closed ThijmenDam closed 2 months ago
I had also reported this, and think i've found the fix https://github.com/ajeetdsouza/zoxide/pull/785
For instance, consider the command z
followed by a tab.
z foo<Tab>
will give you local directory completions. z foo<Space><Tab>
will pull up interactive completions. Are you adding a <Space>
?
Also, have you called compinit
before initializing zoxide?
compinit
is not called, zoxide will not initialize completionscompinit
is called after zoxide, it will reset the completions for zoxideAre you adding a space?
Yes, I use z foo<Space><Tab>
Also, have you called
compinit
before initializing zoxide?
Should I explicitly call this command in my ~/.zshrc
file? Currently, the file looks like this:
eval "$(starship init zsh)"
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
eval "$(zoxide init zsh)"
Do you need any other information?
Should I explicitly call this command in my
~/.zshrc
file?
Yup. Add this right at the start of your zshrc file:
autoload -Uz compinit
compinit
Yup. Add this right at the start of your zshrc file:
autoload -Uz compinit compinit
This has resolved the issue. Thank you very much for the support @ajeetdsouza!
Same issue here, I just use normal oh my zsh, is it possible to use this SPC TAB trick? May I ask what your shell config is? @ThijmenDam
@HaskellZhangSong output of cat ~/.zshrc
:
# necessary for z <path><space><tab> to work
autoload -Uz compinit
compinit
# Pytthon
if command -v pyenv 1>/dev/null 2>&1; then
eval "$(pyenv init --path)"
fi
# ll command
alias ll='ls -la'
# NVM
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
eval "$(starship init zsh)"
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
eval "$(zoxide init zsh)"
I have trouble getting the interactive mode to work using the space + tab keyboard shortcut.
For instance, consider the command
z <some-dir>
followed by a tab. Instead of going into interactive mode, my terminal shows the files/directories under thez <some-dir>
command as if I had typed thels
command:I have installed
zoxide
andfzf
according to their installation instructions, i.e. my~/.zshrc
file ends with the following two lines:I use a fresh install of macOS 14.4.1.
Does anybody else experience this issue?