Answer the question
In order to leave comments, you need to log in
How to run compgen using sudo?
Good afternoon.
There is a Go product that uses bash autocomlete (command[TAB]).
Command completion works correctly for both normal user and super user. However, if we try to use autocompletion by running the command with sudo, it will throw an error.
$ sudo ./util cl[TAB]
bash: compgen: warning: -C option may not work as expected
Command not found: compgen
Display all 221 possibilities? (y or n)
$ sudo compgen -c
sudo: compgen: command not found
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question