On Thu, May 19, 2022 at 03:54 Kamil Jońca <kjo...@o2.pl> wrote: > Tom Browder <tom.brow...@gmail.com> writes: > > > I need a special path setting for root after both "sudo" and "sudo su." > How can I set that up correctly? > > It is quite misterious for me. > What is the purpose of "sudo su" instead of plain "sudo" or "sudo -i"
KJ, and others, let me describe my specific use case: As a normal user, I have developed a single script written in Raku ( https://raku.org) that does a lot of work to collect all requirements to build and install the latest OpenSSL and Apache2 httpd. The install step requires: $ sudo ./myprog install or $ sudo su # ./myprog install The "myprog" program has a shebang line that requires a path to the pertinent Raku executables. That line looks like this: #!/usr/bin/env raku I have for years now not used the many variants of su, just "sudo" alone for one-off use and "sudo su" when I'm doing several things as root. That serves me well for most everything I do on Debian. I am not a full-time sysadmin, so I don't spend a lot of time with the hard details--I try to simplify things as much as I reasonably can. Thanks. -Tom P.S. You Perl people should seriously investigate Raku--it's a better Perl, Perl on steriods!