Fix check for run as root

feature/container-notifications
trivernis 1 year ago
parent c9024fa312
commit 8509cf2622
Signed by: Trivernis
GPG Key ID: DFFFCC2C7A02DB45

@ -6,15 +6,9 @@ use cntfy.nu
def main [
--ntfy: bool
] {
if is-admin == false {
let span = (metadata main).span;
err make {
if ( is-admin ) == false {
error make {
msg: "This script needs to be run as root"
label: {
text: "Run as root"
start: $label.start
end: $label.end
}
}
}
let updates = ( checkupdates | split row "\n" )

Loading…
Cancel
Save