[CLI][List] Various fixes to --only-names
- Added missing groups - Sorted - Don't show outputs when using --only-pre and no preflights
This commit is contained in:
parent
ef04782a9a
commit
b28ea6d6cd
|
|
@ -133,12 +133,16 @@ GS.kibot_version = __version__
|
||||||
|
|
||||||
def list_pre_and_outs_names(logger, outputs, do_config, only_pre, only_groups):
|
def list_pre_and_outs_names(logger, outputs, do_config, only_pre, only_groups):
|
||||||
pf = BasePreFlight.get_in_use_names()
|
pf = BasePreFlight.get_in_use_names()
|
||||||
if len(pf) and only_pre:
|
if only_pre:
|
||||||
for c in pf:
|
for c in sorted(pf):
|
||||||
logger.info(c)
|
logger.info(c)
|
||||||
return
|
return
|
||||||
if len(outputs):
|
if only_groups:
|
||||||
for o in outputs:
|
for g in sorted(RegOutput.get_group_names()):
|
||||||
|
logger.info(g)
|
||||||
|
return
|
||||||
|
if outputs:
|
||||||
|
for o in sorted(outputs, key=lambda x: x.name.lower()):
|
||||||
if do_config:
|
if do_config:
|
||||||
config_output(o, dry=False)
|
config_output(o, dry=False)
|
||||||
logger.info(o.name)
|
logger.info(o.name)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue