The conf module currently does not provide a means to figure out what
configuration entries are available.
This commit adds a method that allows the caller to figure out what
configuration settings are available in a given configuration domain.
return 0
}
+
+conf_get_names() {
+ local config="$1"
+
+ local confpath
+
+ if [[ -z "$config" ]]; then
+ config="default"
+ fi
+
+ confpath="$__conf_root/$config.conf"
+
+ if ! grep -oP "^\\K[^=]+" < "$confpath"; then
+ return 1
+ fi
+
+ return 0
+}