mirror of
https://codeberg.org/scip/esctl.git
synced 2026-08-24 06:34:18 +02:00
add -p -t -D flags to cluster settings ls (#10)
This commit is contained in:
@@ -147,7 +147,16 @@ func ClusterSettingsList(conf *cfg.Config) error {
|
||||
table.Addheaders("setting", "value")
|
||||
entries := [][]string{}
|
||||
|
||||
for topic, val := range res.Persistent {
|
||||
settingshash := res.Persistent // == map[string]json.RawMessage
|
||||
|
||||
switch {
|
||||
case conf.Transient:
|
||||
settingshash = res.Transient
|
||||
case conf.Default:
|
||||
settingshash = res.Defaults
|
||||
}
|
||||
|
||||
for topic, val := range settingshash {
|
||||
data := map[string]map[string]any{}
|
||||
|
||||
err := json.Unmarshal(val, &data)
|
||||
|
||||
Reference in New Issue
Block a user