Add a function to check whether a config is set
This commit is contained in:
parent
474ac2d94b
commit
a3d2bed4cf
|
@ -4,6 +4,10 @@ function getConfig -S -a property
|
|||
evalModule "$CONFIG_MODULE" "$property" $argv[2..]
|
||||
end
|
||||
|
||||
function isSet -S -a property
|
||||
not test "$(getConfig "$property" --json)" = "null"
|
||||
end
|
||||
|
||||
function collectionActive -S -a name
|
||||
[ "$(getConfig "valhalla.software.$name" --json)" = "true" ]
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue