RETIRED, Gerrit as used by OpenStack
e51c428fe5
Show one line description for each ssh command. Make COMMAND argument optional, so that --help argument is not needed. This approach is working for core gerrit commands, aliases, nested commands and plugin's own ssh commands. To provide a description ssh command must be annotated with CommandMetaData annotation, i. e.: @CommandMetaData(name="print", descr="Print greeting in different languages") public final class PrintHelloWorldCommand extends SshCommand { ... Syntactic sugar for command registration is provided to reflect the fact, that both name and description are included in CommandMetaData annotation. To register command and alias in plugin: protected void configureCommands() { command(PrintHelloWorldCommand.class); alias("say-hello", PrintHelloWorldCommand.class); [...] With the outcome: $ ssh gerrit helloworld Available commands of helloworld are: print Print greeting in different languages say-hello Print greeting in different languages Change-Id: I2e5440378023ecc5425092d8131f121da2f20a30 |
||
---|---|---|
contrib | ||
Documentation | ||
gerrit-antlr | ||
gerrit-cache-h2 | ||
gerrit-common | ||
gerrit-extension-api | ||
gerrit-gwtdebug | ||
gerrit-gwtui | ||
gerrit-httpd | ||
gerrit-launcher | ||
gerrit-main | ||
gerrit-openid | ||
gerrit-package-plugins | ||
gerrit-patch-commonsnet | ||
gerrit-patch-jgit | ||
gerrit-pgm | ||
gerrit-plugin-api | ||
gerrit-plugin-archetype | ||
gerrit-plugin-gwt-archetype | ||
gerrit-plugin-gwtui | ||
gerrit-plugin-js-archetype | ||
gerrit-prettify | ||
gerrit-reviewdb | ||
gerrit-server | ||
gerrit-sshd | ||
gerrit-util-cli | ||
gerrit-util-ssl | ||
gerrit-war | ||
ReleaseNotes | ||
tools | ||
.gitignore | ||
COPYING | ||
INSTALL | ||
pom.xml | ||
SUBMITTING_PATCHES |