0

So there is this location ~/.local/share/nvim/mason/.packages for mason to properly install packages it apparently needs to be able to remove stuff within this folder

however my user doesn't have perm to delete this as manually doing rm -rf .packages returns these errors:

rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/zh-cn/diagnosticMessages.generated.json': Permission denied
rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/lib.es2020.date.d.ts': Permission denied
rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/lib.es2017.object.d.ts': Permission denied
rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/lib.es2023.array.d.ts': Permission denied
rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/lib.webworker.iterable.d.ts': Permission denied
rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/lib.es2015.d.ts': Permission denied
rm: cannot remove '.packages/typescript-language-server/node_modules/typescript/lib/lib.es2017.string.d.ts': Permission denied

however I have used: sudo chown cyneptic:cyneptic .packages - to get perm and the perm shows drwxr-xr-x 7 cyneptic cyneptic 4096 Apr 14 01:32 .

but I can't delete it as cyneptic.

waltinator's pathlld output:

drwxr-xr-x 19 root root 4096 Apr 14 09:42 /
/dev/sdb on / type ext4 (rw,relatime,discard,errors=remount-ro,data=ordered)
drwxr-xr-x 3 root root 4096 Apr 13 18:02 /home
drwxr-x--- 13 cyneptic cyneptic 4096 Apr 14 09:58 /home/cyneptic
drwx------ 4 cyneptic cyneptic 4096 Apr 13 21:44 /home/cyneptic/.local
drwx------ 3 cyneptic cyneptic 4096 Apr 13 21:44 /home/cyneptic/.local/share
drwx------ 4 cyneptic cyneptic 4096 Apr 14 09:57 /home/cyneptic/.local/share/nvim
drwxr-xr-x 7 cyneptic cyneptic 4096 Apr 14 02:12 /home/cyneptic/.local/share/nvim/mason
drwxr-xr-x 2 cyneptic cyneptic 4096 Apr 14 02:21 /home/cyneptic/.local/share/nvim/mason/.packages
  • Either the partition is mounted Read-Only, or you don't have Write permission for the parent directory. Explore your Mount/Read/Write/Execute problems with `https://github.com/waltinator/pathlld`, a `bash` script to show the permissions, mount options along the path to an object or objects. – waltinator Apr 14 '23 at 01:26
  • edited the output in the original post as it didn't fit in the comments. – Sombre Dreamer Apr 14 '23 at 06:30

0 Answers0