`kool self-update` insists on elevated permission when not necessary
magne opened this issue · comments
Describe the bug
When kool
is installed in a location writable by the current user, kool self-update
should not require elevated privileges.
Kool version and environment
kool version 1.13.2
Ubuntu 21.04
To Reproduce
$ curl -fsSL https://kool.dev/install | BIN_PATH=$HOME/bin/kool bash
$ kool self-update
[error] Updating kool version
you need to use 'sudo' to perform this task
$
Expected behavior
Since $HOME/bin/kool
is writable by the current user, I would expect kool self-update
to update itself.
Thanks for the ticket @magne !
We have added that because the usual installation under Linux does require it... we can improve it to really check the "writeability" of the current user on the binary, hence only showing the alert when really necessary.
PR ready #381 - should go into next release.
This has been implemented within our latest release 1.15.0.