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
user$ luarocks install busted
Error: command 'install' requires exclusive access to /usr - use --force-lock to overwrite the lock
I think it would have been better (looking at current distro, security, package manager trends) to install locally by default. I think pip, npm do it this way. #1491 doesn't inspire confidence to say the least. Failing local per-default that I expected to find a way to install locally with a command-line parameter.
luarocks --local install busted actually works, but it's not under luarocks install --help instead it's in luarocks --help global help:
--tree <tree> Which tree to operate on.
--local Use the tree in the user's home directory.
To enable it, see '/usr/bin/luarocks help path'.
--global Use the system tree when `local_by_default` is `true`.
I missed it until I went digging for this option, because I expected this option to appear in my activity scope, so to say, in luarocks install --help. Added terminology (tree) doesn't help either without RTFMing. And all I wanted was to run a package's tests...
I suggest the above error message to be extended:
"Use --local if you want to install locally for your user"
What is a lock anyway? I can only guess that /usr meant the system directory /usr/. It'd help here and in cases where the path was set to God-knows-where to also provide a uid/gid stat for that path (nix only): Error: command 'install' requires exclusive access to /usr (root:root) - use --force-lock to overwrite the lock
$ stat --format '(%U:%G)' /usr
(root:root)
The text was updated successfully, but these errors were encountered:
Since we already understand that we don't have root permissions, suggesting --local and/or --tree as user level alternatives at this point actually sounds like a pretty good idea.
luarocks/src/luarocks/cmd.lua
Lines 751 to 763 in f8579e9
I think it would have been better (looking at current distro, security, package manager trends) to install locally by default. I think pip, npm do it this way. #1491 doesn't inspire confidence to say the least. Failing local per-default that I expected to find a way to install locally with a command-line parameter.
luarocks --local install busted
actually works, but it's not underluarocks install --help
instead it's inluarocks --help
global help:I missed it until I went digging for this option, because I expected this option to appear in my activity scope, so to say, in
luarocks install --help
. Added terminology (tree) doesn't help either without RTFMing. And all I wanted was to run a package's tests...I suggest the above error message to be extended:
/usr
meant the system directory /usr/. It'd help here and in cases where the path was set to God-knows-where to also provide a uid/gid stat for that path (nix only):Error: command 'install' requires exclusive access to /usr (root:root) - use --force-lock to overwrite the lock
The text was updated successfully, but these errors were encountered: