suggest data sources to use for a command (#2518)

Co-authored-by: Colin Delahunty <72827203+colin99d@users.noreply.github.com>
This commit is contained in:
DidierRLopes
2022-09-14 17:17:01 +03:00
committed by GitHub
parent d508c5e815
commit f4bbcbc31c

View File

@@ -69,6 +69,9 @@ class SourcesController(BaseController):
choices: dict = {c: {} for c in self.controller_choices}
choices["get"] = {c: None for c in list(self.commands_with_sources.keys())}
choices["set"] = {c: None for c in list(self.commands_with_sources.keys())}
for cmd in list(self.commands_with_sources.keys()):
choices["set"][cmd] = {c: None for c in self.commands_with_sources[cmd]}
self.completer = NestedCompleter.from_nested_dict(choices)
def print_help(self):