File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ hasTar=$(has tar)
16
16
hasCpio=$( has cpio)
17
17
hasSudo=$( has sudo)
18
18
hasDoas=$( has doas)
19
+ hasRun0=$( has run0)
19
20
hasWget=$( has wget)
20
21
hasCurl=$( has curl)
21
22
hasSetsid=$( has setsid)
Original file line number Diff line number Diff line change @@ -54,6 +54,7 @@ hasTar=
54
54
hasCpio=
55
55
hasSudo=
56
56
hasDoas=
57
+ hasRun0=
57
58
hasWget=
58
59
hasCurl=
59
60
hasSetsid=
@@ -528,7 +529,7 @@ importFacts() {
528
529
529
530
# Necessary to prevent Bash erroring before printing out which fact had an issue
530
531
set +u
531
- for var in isOs isArch isInstaller isContainer isRoot hasIpv6Only hasTar hasCpio hasSudo hasDoas hasWget hasCurl hasSetsid; do
532
+ for var in isOs isArch isInstaller isContainer isRoot hasIpv6Only hasTar hasCpio hasSudo hasDoas hasRun0 hasWget hasCurl hasSetsid; do
532
533
if [[ -z ${! var} ]]; then
533
534
abort " Failed to retrieve fact $var from host"
534
535
fi
@@ -541,9 +542,11 @@ importFacts() {
541
542
maybeSudo=sudo
542
543
elif [[ ${hasDoas} == " y" ]]; then
543
544
maybeSudo=doas
545
+ elif [[ ${hasRun0} == " y" ]]; then
546
+ maybeSudo=run0
544
547
else
545
548
# shellcheck disable=SC2016
546
- abort ' Unable to find a command to use to escalate privileges: Could not find `sudo` or `doas `'
549
+ abort ' Unable to find a command to use to escalate privileges: Could not find `sudo`, `doas` or `run0 `'
547
550
fi
548
551
}
549
552
You can’t perform that action at this time.
0 commit comments