ajeetdsouza / zoxide

A smarter cd command. Supports all major shells.
MIT License
20.54k stars 523 forks source link

cd:1: maximum nested function level reached; increase FUNCNEST? #700

Closed JonasFovea closed 5 months ago

JonasFovea commented 5 months ago

Hi, I've just installed zoxide for the first time, after seeing the video by Dreams of Autonomy, which was great!

I then also tried to replace the cd command by adding the following line in my .zshrc file:

eval "$(zoxide init --cmd cd zsh)"

Sourcing it, results in an reoccuring error when running cd afterwards:

~ cd /whatever
cd:1: maximum nested function level reached; increase FUNCNEST?

After displaying the error message, the current working directory hasn't changed. Removing the --cmd cd option solves this problem when using the z command instead.

Did I do something wrong?

My system is running Ubuntu 22.04, using the zsh.

AnshumanNeon commented 5 months ago

i think you can just keep that line as it is and add this to your .zshrc file

alias cd=z
JonasFovea commented 5 months ago

Yes, that's true. But if there is an argument especially for doing this, I'd rather do that.

And if there is a bug in this feature, it should be fixed...

NzudemK commented 5 months ago

I have the same issue. If i do zoxide -V i get zoxide v0.4.3-unknown, so maybe there is a problem with the package version.

ajeetdsouza commented 5 months ago

Duplicate of https://github.com/ajeetdsouza/zoxide/issues/694; your zoxide is out of date.