use of picocli.CommandLine.Help.TextTable in project keycloak by keycloak.
the class SubCommandListRenderer method render.
@Override
public String render(Help help) {
CommandSpec spec = help.commandSpec();
if (spec.subcommands().isEmpty()) {
return "";
}
Column commands = new Column(24, 2, Column.Overflow.SPAN);
Column descriptions = new Column(spec.usageMessage().width() - 24, 2, Column.Overflow.WRAP);
TextTable textTable = TextTable.forColumns(help.colorScheme(), commands, descriptions);
textTable.setAdjustLineBreaksForWideCJKCharacters(spec.usageMessage().adjustLineBreaksForWideCJKCharacters());
addHierarchy(spec.subcommands().values(), textTable, "");
return textTable.toString();
}
Aggregations