You are not logged in.
I am trying to edit a file that is stored in a directory outside my home, so I need root privileges to save the file.
When I go to hit save, it prompts with the usual "Failed to save 'index.html': Insufficient permissions. Select 'Retry as Sudo' to retry as superuser."
So I click Retry as Sudo and it prompts me for the password. This seems to work fine, but once I put in the password, VS Code displays the error:
"Failed to save 'index.html': Command failed: cd "/home/caleb"; "/usr/bin/pkexec" --disable-internal-agent /bin/bash -c "echo SUDOPROMPT; \"/usr/lib/electron19/bin/code-oss\" --file-write \"/home/caleb/.config/Code - OSS/code-elevated-JBakeENX\" \"/srv/http/secret-message/index.html\"" /bin/bash: line 1: /usr/lib/electron19/bin/code-oss: No such file or directory"
There's a lot in this error message and I'm not sure how to interpret it. It is true, there is no /bin folder inside /usr/lib/electron19/. How do I fix it?
Offline
See https://bugs.archlinux.org/task/61516. I believe you are out of luck.
See https://github.com/jorangreef/sudo-prompt/issues/113 for the other side.
There is a lot of this use-everything-our-way-or-be-damned about, it seems ....
Last edited by cfr (2022-12-23 04:07:05)
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
vscode seems to try a semi-hardcoded path (edit: the path is actually provided by electron19 and where that binary resides. Still mickeysoft)
You could probably just
sudo mkdir -p /usr/lib/electron19/bin
sudo ln -s /usr/bin/code-oss /usr/lib/electron19/bin/code-oss
?
Last edited by seth (2022-12-24 14:54:27)
Online
vscode seems to try a semi-hardcoded path (edit: the path is actually provided by electron19 and where that binary resides. Still mickeysoft)
You could probably justsudo mkdir -p /usr/lib/electron19/bin sudo ln -s /usr/bin/code-oss /usr/lib/electron19/bin/code-oss
?
Doesn't work, /usr/lib/electron19 already exists but it is a shell script
Offline
Not in https://archlinux.org/packages/communit … lectron19/
pacman -Qo /usr/lib/electron19
pacman -Qikk electron19
cat /usr/lib/electron19
Online