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
When setting up zinit in a home directory in an NFS server, that is mounted in different machines in different directories then symlinked to /home, the links in the completions directory will be broken, because they will be absolute and resolved to real paths:
For example:
$ ls ~/.local/share/zinit/completions | grep _scala
lrwxrwxrwx 1 dmiranda users 118 Nov 1 06:41 _scala -> /mnt/long_meaningless_path/user/home/dmiranda/.local/share/zinit/plugins/zsh-users---zsh-completions/src/_scala
This breaks when I log into a different machine using the same home directory, but that has it mounted somewhere else. As a user, it should be invisible to me, as my home dir is always correctly linked to /home/dmiranda, but the symlinks being made absolute and real breaks it completions when I move between machines.
If they were linked just as /home/dmiranda/... things would still work as expected.
I see here we list the completions files explicitly as absolute real paths:
I believe the links should be made relative if possible, or at the least, make it an option to not realise paths, so they at become links to /home/dmiranda (or whatever is in ZINIT[HOME_DIR], ZINIT[PLUGINS_DIR], etc).
Steps to reproduce
Create a directory anywhere in your system, example /mnt/test_user.
Symlink /home/test_user to /mnt/test_user
Install plugins with zinit as test_user. The completions directory will have symlinks pointing to /mnt/test_user.
What happened?
When setting up zinit in a home directory in an NFS server, that is mounted in different machines in different directories then symlinked to
/home
, the links in the completions directory will be broken, because they will be absolute and resolved to real paths:For example:
This breaks when I log into a different machine using the same home directory, but that has it mounted somewhere else. As a user, it should be invisible to me, as my home dir is always correctly linked to
/home/dmiranda
, but the symlinks being made absolute and real breaks it completions when I move between machines.If they were linked just as
/home/dmiranda/...
things would still work as expected.I see here we list the completions files explicitly as absolute real paths:
zinit/zinit-install.zsh
Line 563 in 0c471af
I believe the links should be made relative if possible, or at the least, make it an option to not realise paths, so they at become links to
/home/dmiranda
(or whatever is inZINIT[HOME_DIR]
,ZINIT[PLUGINS_DIR]
, etc).Steps to reproduce
/mnt/test_user
./home/test_user
to/mnt/test_user
test_user
. The completions directory will have symlinks pointing to/mnt/test_user
./mnt/test_user
, update/home/test_user
symlink.zinit
again, completions will be missing due to broken symlinks.Relevant output
No response
Screenshots and recordings
No response
Operating System & Version
OS: linux-gnu | Vendor: debian | Machine: x86_64 | CPU: x86_64 | Processor: unknown | Hardware: x86_64
Zsh version
zsh 5.8 (x86_64-debian-linux-gnu)
Terminal emulator
irrelevant (iTerm2)
If using WSL on Windows, which version of WSL
None
Additional context
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: