[COFF] Other OSes?

Ralph Corderoy ralph at inputplus.co.uk
Fri Jul 6 15:59:30 AEST 2018


Hi Ted,

>     if [[ $EUID -ne 0 ]]; then
...
> (Note that I needed to use /bin/bash instead of a PODIX /bin/sh
> because I needed access to the effective uid via $EUID.)

id(1) `-u' option?

    $ ls -l id
    -rwsr-xr-x 1 31415 31415 38920 Jul  6 06:51 id
    $ ./id
    uid=1000(ralph) gid=1000(ralph) euid=31415 groups=1000(ralph),10(wheel),14(uucp),100(users)
    $ ./id -u
    31415
    $ ./id -ru
    1000
    $ 

-- 
Cheers, Ralph.
https://plus.google.com/+RalphCorderoy


More information about the COFF mailing list