Skip to content

chromebook-setup.sh: remove sudo from ensure_command()

Emil Velikov requested to merge evelikov/chromebooks:sent/remove-sudo into master

Some Debian versions, at least, omit /bin/ /sbin/ and similar paths from the PATH directory. The sudo 'trick' here is used to catch those, since handful of the tools themselves live in those places. And they do not require root privileges to be run.

IMHO a better solution is to tweak PATH locally to include those. This way things will just work across various Debian versions and other distros.

Note: As-is this will break on ancient Debian systems which have not made the /usr switch yet. Do we care about those, if so input how to cater for them is appreciated.

Merge request reports