|
|
@ -6,15 +6,9 @@ use cntfy.nu
|
|
|
|
def main [
|
|
|
|
def main [
|
|
|
|
--ntfy: bool
|
|
|
|
--ntfy: bool
|
|
|
|
] {
|
|
|
|
] {
|
|
|
|
if is-admin == false {
|
|
|
|
if ( is-admin ) == false {
|
|
|
|
let span = (metadata main).span;
|
|
|
|
error make {
|
|
|
|
err make {
|
|
|
|
|
|
|
|
msg: "This script needs to be run as root"
|
|
|
|
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" )
|
|
|
|
let updates = ( checkupdates | split row "\n" )
|
|
|
|