mirror of
https://github.com/fspc/gbootroot.git
synced 2025-02-23 17:13:22 -05:00
Added /sbin and /usr/sbin in case non-root users don't have this path.
This commit is contained in:
parent
38019163a5
commit
8994d775f7
10
gbootroot
10
gbootroot
@ -89,6 +89,16 @@ BEGIN {
|
|||||||
unshift(@INC,"/usr/share/perl5");
|
unshift(@INC,"/usr/share/perl5");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
my $sbin = grep(/\/usr\/sbin/,$ENV{'PATH'});
|
||||||
|
if ($sbin == 0) {
|
||||||
|
$ENV{'PATH'} = "/usr/sbin:" . $ENV{'PATH'};
|
||||||
|
}
|
||||||
|
|
||||||
|
$sbin = grep(/\/sbin/,$ENV{'PATH'});
|
||||||
|
if ($sbin == 0) {
|
||||||
|
$ENV{'PATH'} = "/sbin:" . $ENV{'PATH'};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user