Add a function to check whether a config is set

This commit is contained in:
Manuel Thalmann 2024-07-15 14:14:07 +02:00
parent 474ac2d94b
commit a3d2bed4cf

View file

@ -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