On Thu, Aug 22, 2024 at 13:09:06 +0300, Dmitrii Odintcov wrote:
Let's say I want to install VS Code / Codium as an alternative for `/usr/bin/editor`, but I want it to always run with `--wait
--reuse-window` so that other software can rely on the editor
returning after the file is saved (like `crontab -e` does, for
example)
I cannot do `update-alternatives --install /usr/bin/editor editor
"$(which codium) --wait --reuse-window" 0` because the "alternative
path doesn't exist".
Suggestions?
Write a wrapper script like
#!/bin/sh
exec codium --wait --reuse-window "$@"
and use this script as the symlink target of /usr/bin/editor (do it
manually, not with update-alternatives). Don't forget to chmod 755.
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)