You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think I know what the problem is for Yazi (and likely zoxide, too). Yazi has this recommended wrapper for PowerShell to CD into the last directory used:
I don't know much PowerShell, but I'm guessing that @Wu-Felix's issue is caused because the custom Set-Location takes -Path, but the Yazi wrapper uses -LiteralPath. So the y wrapper fails to CD ("jump").
Perhaps this can be easily fixed by accepting and passing any parameter from the custom Set-Location to the builtin Set-Location for better compatibility? Here's a simple example of what I mean:
functionSet-Location-Proxy {
# do somethingSet-Location@args
}
spenserblack
changed the title
PowerShell snippet can break tools that wrap Set-Location (cd)
PowerShell snippet to run onefetch on directory change can break tools that wrap Set-Location (cd)
Nov 12, 2024
Originally posted by @Wu-Felix in #1452 (comment)
The text was updated successfully, but these errors were encountered: