Closed Treit closed 4 months ago
I encountered the same problem. And it seems you are using the starship, too. The powershell setup line should be added below the starship setup line. After the change, open a new pwsh to test. Then the zoxide should work.
also facing this issue with the zoxide
line at the bottom of my config
I can confirm that moving the zoxide init line to after the Starship init line seems to have fixed it.
Invoke-Expression (&starship init powershell)
Invoke-Expression (& { (zoxide init powershell | Out-String) })
i dont have starship(i use oh-my-posh)...
@pybash1 oh-my-posh
is also a custom prompt and has the same issue. You can resolve this by moving Invoke-Expression (& { (zoxide init powershell | Out-String) })
to the last line in your config.
Moving init to the end of pwsh config helped me too. Thanks!
UPDATE: No, it doesn't work (somehow one path was added but not more). Actually it shouldn't help in my case as other entries are function definitions in my profile.
will have to be moving from so much hyped zoxide.
@alex1yaremchuk can you create an issue describing your problem?
@alex1yaremchuk can you create an issue describing your problem?
I had the same issue. What tripped me up is that once Invoke-Expression (& { (zoxide init powershell | Out-String) })
runs too early (before starship), rerunning it will not fix the issues. The only fix is to reorder them in you $PROFILE, you can't test it after a wrongly-ordered has already been executed. I don't know why, that's just what my testing shows. For reference my order after the fix is: PSReadLine, starship, zoxide and posh-git, and everything seems to work well.
I installed zoxide via
cargo install zoxide
and added the line to my PowerShell (pwsh) $profile per the installation instructions:I can switch to directories but it doesn't seem to record them:
Not sure how to troubleshoot it further.