diff options
author | Christian Aistleitner <christian@quelltextlich.at> | 2020-05-31 11:07:34 +0200 |
---|---|---|
committer | Christian Aistleitner <christian@quelltextlich.at> | 2020-07-03 13:57:59 +0200 |
commit | 99dd23233420e6c9bf919990b42a572111cf44fb (patch) | |
tree | fd9f7ad600266d9aa63a9b2537123dda27604810 | |
parent | c3afed68787074c51bb3360414cf0f84b6f27642 (diff) |
Add Api version to `plugin ls` Ssh command text format
Change-Id: Ic65ad10f8569e8c398bade8b25846d4a44207051
-rw-r--r-- | java/com/google/gerrit/sshd/commands/PluginLsCommand.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/java/com/google/gerrit/sshd/commands/PluginLsCommand.java b/java/com/google/gerrit/sshd/commands/PluginLsCommand.java index 15142bd982..4effa3aeba 100644 --- a/java/com/google/gerrit/sshd/commands/PluginLsCommand.java +++ b/java/com/google/gerrit/sshd/commands/PluginLsCommand.java @@ -49,15 +49,17 @@ public class PluginLsCommand extends SshCommand { .toJson(output, new TypeToken<Map<String, PluginInfo>>() {}.getType(), stdout); stdout.print('\n'); } else { - stdout.format("%-30s %-10s %-8s %s\n", "Name", "Version", "Status", "File"); + String template = "%-30s %-10s %-16s %-8s %s\n"; + stdout.format(template, "Name", "Version", "Api-Version", "Status", "File"); stdout.print( "-------------------------------------------------------------------------------\n"); for (Map.Entry<String, PluginInfo> p : output.entrySet()) { PluginInfo info = p.getValue(); stdout.format( - "%-30s %-10s %-8s %s\n", + template, p.getKey(), Strings.nullToEmpty(info.version), + Strings.nullToEmpty(info.apiVersion), status(info.disabled), Strings.nullToEmpty(info.filename)); } |