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
In dash and bash, an empty directory name in CDPATH means the current working directory so setting CDPATH to :/ has the same meaning as setting it to .:/. Fish doesn't have this default though:
dash$ export CDPATH=":/"
dash$ cd Desktop #this works
dash$ cd ..
dash$ fish # Now lets see what happens in fish
fish$ cd Desktop
cd: The directory “Desktop” does not exist
The motivation for me reporting this is that this problem is a bit similar to the problem in #2090. Other shells might append to the CDPATH using CDPATH=$CDPATH:/blah and that will leave a colon at the start if CDPATH is previously unset. In that case, when Fish breaks it down into an array the first element will be the empty string.
In dash and bash, an empty directory name in CDPATH means the current working directory so setting CDPATH to
:/has the same meaning as setting it to.:/. Fish doesn't have this default though:The motivation for me reporting this is that this problem is a bit similar to the problem in #2090. Other shells might append to the CDPATH using
CDPATH=$CDPATH:/blahand that will leave a colon at the start if CDPATH is previously unset. In that case, when Fish breaks it down into an array the first element will be the empty string.