FELIX-1643: Improvements / Fixes for Karaf commands and their helps
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@818847 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/AddUrlCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/AddUrlCommand.java
index 78c207d..2a3141a 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/AddUrlCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/AddUrlCommand.java
@@ -23,10 +23,10 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "features", name = "addUrl", description = "Add a list of repository URLs to the features service.")
+@Command(scope = "features", name = "addUrl", description = "Adds a list of repository URLs to the features service.")
public class AddUrlCommand extends FeaturesCommandSupport {
- @Argument(required = true, multiValued = true, description = "Repository URLs")
+ @Argument(index = 0, name = "urls", description = "One or more repository URLs separated by whitespaces", required = true, multiValued = true)
List<String> urls;
protected void doExecute(FeaturesService admin) throws Exception {
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/InstallFeatureCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/InstallFeatureCommand.java
index aff684d..67a0571 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/InstallFeatureCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/InstallFeatureCommand.java
@@ -20,12 +20,12 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "features", name = "install", description = "Install a feature.")
+@Command(scope = "features", name = "install", description = "Installs a feature with the specified name and version.")
public class InstallFeatureCommand extends FeaturesCommandSupport {
- @Argument(required = true, description = "The name of the feature")
+ @Argument(index = 0, name = "name", description = "The name of the feature", required = true, multiValued = false)
String name;
- @Argument(description = "The version of the feature", index = 1)
+ @Argument(index = 1, name = "version", description = "The version of the feature", required = false, multiValued = false)
String version;
protected void doExecute(FeaturesService admin) throws Exception {
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListFeaturesCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListFeaturesCommand.java
index 63efe72..ebdeb06 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListFeaturesCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListFeaturesCommand.java
@@ -28,10 +28,10 @@
import org.apache.felix.gogo.commands.Option;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "features", name = "list", description = "List existing features.")
+@Command(scope = "features", name = "list", description = "Lists all existing features available from the defined repositories.")
public class ListFeaturesCommand extends FeaturesCommandSupport {
- @Option(name = "-i", aliases={"--installed"}, description="Display the list of installed features")
+ @Option(name = "-i", aliases={"--installed"}, description="Display a list of all installed features only", required = false, multiValued = false)
boolean installed;
private static final String STATE = "State";
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListUrlCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListUrlCommand.java
index e9c5306..79b280b 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListUrlCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/ListUrlCommand.java
@@ -18,8 +18,9 @@
import org.apache.felix.karaf.features.FeaturesService;
import org.apache.felix.karaf.features.Repository;
+import org.apache.felix.gogo.commands.Command;
-
+@Command(scope = "features", name = "listUrl", description = "Displays a list of all defined repository URLs.")
public class ListUrlCommand extends FeaturesCommandSupport {
protected void doExecute(FeaturesService admin) throws Exception {
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RefreshUrlCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RefreshUrlCommand.java
index 45b400d..de088b2 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RefreshUrlCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RefreshUrlCommand.java
@@ -25,10 +25,10 @@
import org.apache.felix.karaf.features.FeaturesService;
import org.apache.felix.karaf.features.Repository;
-@Command(scope = "features", name = "refreshUrl", description = "Reload the repositories to obtain a fresh list of features.")
+@Command(scope = "features", name = "refreshUrl", description = "Reloads the list of available features from the repositories.")
public class RefreshUrlCommand extends FeaturesCommandSupport {
- @Argument(required = false, multiValued = true, description = "Repository URLs (leave empty for all)")
+ @Argument(index = 0, name = "urls", description = "Repository URLs to reload (leave empty for all)", required = false, multiValued = true)
List<String> urls;
protected void doExecute(FeaturesService admin) throws Exception {
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RemoveUrlCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RemoveUrlCommand.java
index 17db749..c5cfed1 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RemoveUrlCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/RemoveUrlCommand.java
@@ -23,10 +23,10 @@
import org.apache.felix.gogo.commands.Command;
import org.apache.felix.karaf.features.FeaturesService;
-@Command(scope = "features", name = "removeUrl", description = "Remove a list of repository URLs from the features service.")
+@Command(scope = "features", name = "removeUrl", description = "Removes the given list of repository URLs from the features service.")
public class RemoveUrlCommand extends FeaturesCommandSupport {
- @Argument(required = true, multiValued = true, description = "Repository URLs")
+ @Argument(index = 0, name = "urls", description = "One or more repository URLs separated by whitespaces", required = true, multiValued = true)
List<String> urls;
protected void doExecute(FeaturesService admin) throws Exception {
diff --git a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/UninstallFeatureCommand.java b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/UninstallFeatureCommand.java
index 229d43c..4906d78 100644
--- a/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/UninstallFeatureCommand.java
+++ b/karaf/features/command/src/main/java/org/apache/felix/karaf/features/command/UninstallFeatureCommand.java
@@ -20,12 +20,13 @@
import org.apache.felix.gogo.commands.Command;
import org.apache.felix.karaf.features.FeaturesService;
-@Command(scope = "features", name = "uninstall", description = "Uninstall a feature.")
+@Command(scope = "features", name = "uninstall", description = "Uninstalls a feature with the specified name and version.")
public class UninstallFeatureCommand extends FeaturesCommandSupport {
- @Argument(required = true, description = "The name of the feature")
+ @Argument(index = 0, name = "name", description = "The name of the feature", required = true, multiValued = false)
String name;
- @Argument(description = "The version of the feature", index = 1)
+
+ @Argument(index = 1, name = "version", description = "The version of the feature", required = false, multiValued = false)
String version;
protected void doExecute(FeaturesService admin) throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ChangePortCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ChangePortCommand.java
index 04e0899..b632742 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ChangePortCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ChangePortCommand.java
@@ -19,13 +19,13 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "admin", name = "change-port", description = "Change the port of an existing instance.")
+@Command(scope = "admin", name = "change-port", description = "Changes the port of an existing container instance.")
public class ChangePortCommand extends AdminCommandSupport {
- @Argument(index=0, required=true, description="The instance name")
+ @Argument(index = 0, name = "name", description="The name of the container instance", required = true, multiValued = false)
private String instance = null;
- @Argument(index=1, required=true, description="The new port")
+ @Argument(index = 1, name = "port", description = "The new port to set", required = true, multiValued = false)
private int port = 0;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ConnectCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ConnectCommand.java
index 89576d8..e5f2da6 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ConnectCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ConnectCommand.java
@@ -22,16 +22,16 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "admin", name = "connect", description = "Connect to an existing instance.")
+@Command(scope = "admin", name = "connect", description = "Connects to an existing container instance.")
public class ConnectCommand extends AdminCommandSupport {
- @Argument(index=0, name="INSTANCE", required=true, description="The instance name")
+ @Argument(index = 0, name="name", description="The name of the container instance", required = true, multiValued = false)
private String instance = null;
- @Option(name="-u", aliases={"--username"}, description="Remote user name")
+ @Option(name="-u", aliases={"--username"}, description="Remote user name (Default: karaf)", required = false, multiValued = false)
private String username = "karaf";
- @Option(name="-p", aliases={"--password"}, description="Remote user password")
+ @Option(name="-p", aliases={"--password"}, description="Remote user password (Default: karaf)", required = false, multiValued = false)
private String password = "karaf";
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/CreateCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/CreateCommand.java
index e039ea1..277a0cb 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/CreateCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/CreateCommand.java
@@ -26,16 +26,16 @@
*
* @version $Rev: 679826 $ $Date: 2008-07-25 17:00:12 +0200 (Fri, 25 Jul 2008) $
*/
-@Command(scope = "admin", name = "create", description = "Create a new instance.")
+@Command(scope = "admin", name = "create", description = "Creates a new container instance.")
public class CreateCommand extends AdminCommandSupport
{
- @Option(name = "-p", aliases = { "--port"}, description = "Port number for remote shell connection")
+ @Option(name = "-p", aliases = { "--port"}, description = "Port number for remote shell connection", required = false, multiValued = false)
private int port = 0;
- @Option(name = "-l", aliases = { "--location"}, description = "Location of the new instance on the file system")
+ @Option(name = "-l", aliases = { "--location"}, description = "Location of the new container instance in the file system", required = false, multiValued = false)
private String location;
- @Argument(index=0, required=true, description="Name of the new Karaf instance")
+ @Argument(index = 0, name = "name", description="The name of the new container instance", required = true, multiValued = false)
private String instance = null;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/DestroyCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/DestroyCommand.java
index b6ec474..a15edc9 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/DestroyCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/DestroyCommand.java
@@ -24,10 +24,10 @@
*
* @version $Rev: 679826 $ $Date: 2008-07-25 17:00:12 +0200 (Fri, 25 Jul 2008) $
*/
-@Command(scope = "admin", name = "destroy", description = "Destroy an existing instance.")
+@Command(scope = "admin", name = "destroy", description = "Destroys an existing container instance.")
public class DestroyCommand extends AdminCommandSupport
{
- @Argument(index=0, required=true, description="The name of the Karaf instance to destroy")
+ @Argument(index = 0, name = "name", description="The name of the container instance to destroy", required = true, multiValued = false)
private String instance = null;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ListCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ListCommand.java
index f12690a..aacb030 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ListCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/ListCommand.java
@@ -23,10 +23,10 @@
/**
* List available instances
*/
-@Command(scope = "admin", name = "list", description = "List existing instances.")
+@Command(scope = "admin", name = "list", description = "List all existing container instances.")
public class ListCommand extends AdminCommandSupport {
- @Option(name = "-l", aliases = { "--location" }, description = "Display instances location")
+ @Option(name = "-l", aliases = { "--location" }, description = "Displays the location of the container instances", required = false, multiValued = false)
boolean location;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StartCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StartCommand.java
index 424da04..125a4a7 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StartCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StartCommand.java
@@ -20,13 +20,13 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "admin", name = "start", description = "Start an existing instance.")
+@Command(scope = "admin", name = "start", description = "Starts an existing container instance.")
public class StartCommand extends AdminCommandSupport {
- @Option(name = "-o", aliases = { "--java-opts"}, description = "Java options when launching the instance")
+ @Option(name = "-o", aliases = { "--java-opts"}, description = "Java options when launching the instance", required = false, multiValued = false)
private String javaOpts;
- @Argument(index=0, required=true, description="The instance name")
+ @Argument(index = 0, name = "name", description = "The name of the container instance", required = true, multiValued = false)
private String instance = null;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StopCommand.java b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StopCommand.java
index ec3e883..5e0e078 100644
--- a/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StopCommand.java
+++ b/karaf/shell/admin/src/main/java/org/apache/felix/karaf/shell/admin/internal/commands/StopCommand.java
@@ -19,10 +19,10 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "admin", name = "stop", description = "Stop an existing instance.")
+@Command(scope = "admin", name = "stop", description = "Stops an existing container instance.")
public class StopCommand extends AdminCommandSupport {
- @Argument(index=0, required=true, description="The instance name")
+ @Argument(index = 0, name = "name", description = "The name of the container instance", required = true, multiValued = false)
private String instance = null;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/CatAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/CatAction.java
index e4912be..6767955 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/CatAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/CatAction.java
@@ -40,10 +40,10 @@
@Command(scope = "shell", name = "cat", description = "Displays the content of a file or url")
public class CatAction extends OsgiCommandSupport {
- @Option(name="-n", description = "Number the output lines, starting at 1.")
+ @Option(name = "-n", aliases = {}, description = "The number the output lines, starting at 1.", required = false, multiValued = false)
private boolean displayLineNumbers;
- @Argument(required = true, multiValued = true)
+ @Argument(index = 0, name = "paths or urls", description = "A list of file paths or urls to display separated by whitespaces (use - for STDIN)", required = true, multiValued = true)
private List<String> paths;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/EchoAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/EchoAction.java
index 3049683..0a23167 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/EchoAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/EchoAction.java
@@ -7,13 +7,13 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.karaf.shell.console.OsgiCommandSupport;
-@Command(scope = "shell", name = "echo", description="Echo or print arguments to STDOUT")
+@Command(scope = "shell", name = "echo", description="Echoes or prints arguments to STDOUT")
public class EchoAction extends OsgiCommandSupport
{
- @Option(name="-n", description="Do not print the trailing newline character")
+ @Option(name = "-n", aliases = {}, description = "Do not print the trailing newline character", required = false, multiValued = false)
private boolean noTrailingNewline = false;
- @Argument(description="Arguments", multiValued = true)
+ @Argument(index = 0, name = "arguments", description="Arguments to display separated by whitespaces", required = false, multiValued = true)
private List<String> args;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/ExecuteAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/ExecuteAction.java
index 794b24d..c4089b0 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/ExecuteAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/ExecuteAction.java
@@ -28,10 +28,10 @@
*
* @version $Rev: 593392 $ $Date: 2007-11-09 03:14:15 +0100 (Fri, 09 Nov 2007) $
*/
-@Command(scope = "shell", name = "exec", description = "Execute system processes")
+@Command(scope = "shell", name = "exec", description = "Executes system processes")
public class ExecuteAction extends OsgiCommandSupport {
- @Argument(description = "Arguments", required = true, multiValued = true)
+ @Argument(index = 0, name = "command", description = "Execution command with arguments", required = true, multiValued = true)
private List<String> args;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/GrepAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/GrepAction.java
index 9c90036..3b0ed34 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/GrepAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/GrepAction.java
@@ -29,30 +29,30 @@
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "shell", name="grep", description="Print lines matching a pattern")
+@Command(scope = "shell", name="grep", description="Prints lines matching the given pattern")
public class GrepAction extends OsgiCommandSupport {
- @Argument(name = "PATTERN", required = true, description = "Regular expression")
+ @Argument(index = 0, name = "pattern", description = "Regular expression", required = true, multiValued = false)
private String regex;
- @Option(name="-n", aliases = { "--line-number" }, description="Prefix each line of output with the line number within its input file.")
+ @Option(name = "-n", aliases = { "--line-number" }, description = "Prefixes each line of output with the line number within its input file.", required = false, multiValued = false)
private boolean lineNumber;
- @Option(name = "-v", aliases = { "--invert-match" }, description = "Invert the sense of matching, to select non-matching lines.")
+ @Option(name = "-v", aliases = { "--invert-match" }, description = "Inverts the sense of matching, to select non-matching lines.", required = false, multiValued = false)
private boolean invertMatch;
- @Option(name = "-w", aliases = { "--word-regexp" }, description = "Select only those lines containing matches that form whole " +
+ @Option(name = "-w", aliases = { "--word-regexp" }, description = "Selects only those lines containing matches that form whole " +
"words. The test is that the matching substring must either be " +
"at the beginning of the line, or preceded by a non-word constituent " +
"character. Similarly, it must be either at the end of " +
"the line or followed by a non-word constituent character. " +
- "Word-constituent characters are letters, digits, and the underscore.")
+ "Word-constituent characters are letters, digits, and the underscore.", required = false, multiValued = false)
private boolean wordRegexp;
- @Option(name = "-x", aliases = { "--line-regexp" }, description = "Select only those matches that exactly match the whole line.")
+ @Option(name = "-x", aliases = { "--line-regexp" }, description = "Selects only those matches that exactly match the whole line.", required = false, multiValued = false)
private boolean lineRegexp;
- @Option(name = "-i", aliases = { "--ignore-case" }, description = "Ignore case distinctions in both the PATTERN and the input files.")
+ @Option(name = "-i", aliases = { "--ignore-case" }, description = "Ignores case distinctions in both the PATTERN and the input files.", required = false, multiValued = false)
private boolean ignoreCase;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/InfoAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/InfoAction.java
index 1b176d4..91c7f0a 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/InfoAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/InfoAction.java
@@ -33,13 +33,12 @@
import org.apache.felix.gogo.commands.Command;
import org.fusesource.jansi.Ansi;
-@Command(scope = "shell", name = "info", description = "Print Karaf informations")
+@Command(scope = "shell", name = "info", description = "Prints system informations")
public class InfoAction extends OsgiCommandSupport {
private NumberFormat fmtI = new DecimalFormat("###,###", new DecimalFormatSymbols(Locale.ENGLISH));
private NumberFormat fmtD = new DecimalFormat("###,##0.000", new DecimalFormatSymbols(Locale.ENGLISH));
-
protected Object doExecute() throws Exception {
int maxNameLen;
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/JavaAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/JavaAction.java
index c035ca2..47f81c6 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/JavaAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/JavaAction.java
@@ -36,13 +36,13 @@
@Command(scope = "shell", name = "java", description = "Execute a Java standard application")
public class JavaAction extends OsgiCommandSupport {
- @Option(name="-m", aliases={"--method"}, description="Invoke a named method")
+ @Option(name = "-m", aliases = {"--method"}, description = "Invoke a named method", required = false, multiValued = false)
private String methodName = "main";
- @Argument(index=0, name = "className", description="The name of the class to invoke", required=true)
+ @Argument(index = 0, name = "className", description="The name of the class to invoke", required = true, multiValued = false)
private String className;
- @Argument(index=1, name = "args", description="Arguments to pass to the METHOD of CLASSNAME")
+ @Argument(index = 1, name = "arguments", description="Arguments to pass to the method of the given class", required = false, multiValued = false)
private List<String> args;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/PrintfAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/PrintfAction.java
index 889c750..5bd4219 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/PrintfAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/PrintfAction.java
@@ -25,10 +25,10 @@
@Command(scope = "shell", name = "printf", description = "Format and print arguments")
public class PrintfAction extends OsgiCommandSupport {
- @Argument(index=0, required=true)
+ @Argument(index = 0, name = "format", description = "The format pattern to use", required = true, multiValued = false)
private String format;
- @Argument(index=1, multiValued=true, required=true)
+ @Argument(index = 1, name = "arguments", description = "The arguments for the given format pattern", required = true, multiValued = true)
private Collection<Object> arguments = null;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SleepAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SleepAction.java
index 69a09b6..facadd4 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SleepAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SleepAction.java
@@ -20,11 +20,11 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "shell", name = "sleep", description = "Sleep for a bit then wake up")
+@Command(scope = "shell", name = "sleep", description = "Sleeps for a bit then wakes up")
public class SleepAction extends OsgiCommandSupport {
- @Argument(required=true)
- private int time = -1;
+ @Argument(index = 0, name = "duration", description = "The amount of millis to sleep", required = true, multiValued = false)
+ private long time = -1;
protected Object doExecute() throws Exception {
log.info("Sleeping for {}", time);
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SortAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SortAction.java
index 8cd9918..9f375ba 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SortAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/SortAction.java
@@ -44,31 +44,31 @@
*
* @version $Rev: 722776 $ $Date: 2008-12-03 05:59:59 +0100 (Wed, 03 Dec 2008) $
*/
-@Command(scope = "shell", name = "sort", description = "Write sorted concatenation of all FILE(s) to standard output.")
+@Command(scope = "shell", name = "sort", description = "Write sorted concatenation of all files to standard output.")
public class SortAction extends OsgiCommandSupport {
- @Option(name = "-f", aliases = { "-ignore-case" }, description = "fold lower case to upper case characters")
+ @Option(name = "-f", aliases = { "-ignore-case" }, description = "fold lower case to upper case characters", required = false, multiValued = false)
private boolean caseInsensitive;
- @Option(name = "-r", aliases = { "--reverse" }, description = "reverse the result of comparisons")
+ @Option(name = "-r", aliases = { "--reverse" }, description = "reverse the result of comparisons", required = false, multiValued = false)
private boolean reverse;
- @Option(name = "-u", aliases = { "--unique" }, description = "output only the first of an equal run")
+ @Option(name = "-u", aliases = { "--unique" }, description = "output only the first of an equal run", required = false, multiValued = false)
private boolean unique;
- @Option(name = "-t", aliases = { "--field-separator" }, description = "use SEP instead of non-blank to blank transition")
+ @Option(name = "-t", aliases = { "--field-separator" }, description = "use SEP instead of non-blank to blank transition", required = false, multiValued = false)
private String separator;
- @Option(name = "-b", aliases = { "--ignore-leading-blanks" }, description = "ignore leading blanks")
+ @Option(name = "-b", aliases = { "--ignore-leading-blanks" }, description = "ignore leading blanks", required = false, multiValued = false)
private boolean ignoreBlanks;
- @Option(name = "-k", aliases = { "--key" }, multiValued = true)
+ @Option(name = "-k", aliases = { "--key" }, description = "Fields to use for sorting separated by whitespaces", required = false, multiValued = true)
private List<String> sortFields;
- @Option(name = "-n", aliases = { "--numeric-sort" }, description = "compare according to string numerical value")
+ @Option(name = "-n", aliases = { "--numeric-sort" }, description = "compare according to string numerical value", required = false, multiValued = false)
private boolean numeric;
- @Argument(index = 0, required = false, multiValued = true)
+ @Argument(index = 0, name = "files", description = "A list of files separated by whitespaces", required = false, multiValued = true)
private List<String> paths;
diff --git a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/TacAction.java b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/TacAction.java
index 646f4e7..376fcb4 100644
--- a/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/TacAction.java
+++ b/karaf/shell/commands/src/main/java/org/apache/felix/karaf/shell/commands/TacAction.java
@@ -37,10 +37,10 @@
*
* @version $Rev: 593392 $ $Date: 2007-11-09 03:14:15 +0100 (Fri, 09 Nov 2007) $
*/
-@Command(scope = "shell", name = "tac", description = "Capture the stdin and return it as a string. Optionally write the content to a file")
+@Command(scope = "shell", name = "tac", description = "Captures the STDIN and returns it as a string. Optionally writes the content to a file")
public class TacAction extends OsgiCommandSupport {
- @Option(name = "-f", description = "Specify a file to write the content to")
+ @Option(name = "-f", aliases = {}, description = "Outputs the content to the given file", required = false, multiValued = false)
private File file;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/EditCommand.java b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/EditCommand.java
index 7a9e934..ea807f4 100644
--- a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/EditCommand.java
+++ b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/EditCommand.java
@@ -27,10 +27,10 @@
@Command(scope = "config", name = "edit", description = "Create or edit a configuration.")
public class EditCommand extends ConfigCommandSupport {
- @Argument(required = true, description = "PID of the configuration")
+ @Argument(index = 0, name = "pid", description = "PID of the configuration", required = true, multiValued = false)
String pid;
- @Option(name = "--force", description = "Force the edition of this config, even if another one was under edition")
+ @Option(name = "--force", aliases = {}, description = "Force the edition of this config, even if another one was under edition", required = false, multiValued = false)
boolean force;
protected void doExecute(ConfigurationAdmin admin) throws Exception {
diff --git a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/ListCommand.java b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/ListCommand.java
index c4ca570..b0a0eb5 100644
--- a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/ListCommand.java
+++ b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/ListCommand.java
@@ -24,10 +24,10 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "config", name = "list", description = "List existing configurations.")
+@Command(scope = "config", name = "list", description = "Lists existing configurations.")
public class ListCommand extends ConfigCommandSupport {
- @Argument(required = false, description = "LDAP query")
+ @Argument(index = 0, name = "query", description = "Specify a LDAP query", required = false, multiValued = false)
String query;
protected void doExecute(ConfigurationAdmin admin) throws Exception {
diff --git a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropAppendCommand.java b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropAppendCommand.java
index 98762c6..a6a441d 100644
--- a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropAppendCommand.java
+++ b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropAppendCommand.java
@@ -25,13 +25,13 @@
/**
* Appends a value to the current property value.
*/
-@Command(scope = "config", name = "propappend", description = "Append the given value to an existing property or create the property with the specified value.")
+@Command(scope = "config", name = "propappend", description = "Appends the given value to an existing property or creates the property with the specified name and value.")
public class PropAppendCommand extends ConfigCommandSupport {
- @Argument(index = 0, required = true, description = "the property to set")
+ @Argument(index = 0, name = "name", description = "The name of the property", required = true, multiValued = false)
String prop;
- @Argument(index = 1, required = true, description = "the value to be appended")
+ @Argument(index = 1, name = "value", description = "The value to append to the property", required = true, multiValued = false)
String value;
@Override
diff --git a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropDelCommand.java b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropDelCommand.java
index 428ab0c..d6959eb 100644
--- a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropDelCommand.java
+++ b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropDelCommand.java
@@ -22,10 +22,10 @@
import org.apache.felix.gogo.commands.Command;
import org.osgi.service.cm.ConfigurationAdmin;
-@Command(scope = "config", name = "propdel", description = "Delete a property from the edited configuration.")
+@Command(scope = "config", name = "propdel", description = "Deletes a property from the edited configuration.")
public class PropDelCommand extends ConfigCommandSupport {
- @Argument(name = "prop", index = 0, required = true, description = "the property to delete")
+ @Argument(index = 0, name = "property", description = "The name of the property to delete", required = true, multiValued = false)
String prop;
protected void doExecute(ConfigurationAdmin admin) throws Exception {
diff --git a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropListCommand.java b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropListCommand.java
index faeb701..905b664 100644
--- a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropListCommand.java
+++ b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropListCommand.java
@@ -22,7 +22,7 @@
import org.osgi.service.cm.ConfigurationAdmin;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "config", name = "proplist", description = "List properties from the edited configuration.")
+@Command(scope = "config", name = "proplist", description = "Lists properties from the currently edited configuration.")
public class PropListCommand extends ConfigCommandSupport {
protected void doExecute(ConfigurationAdmin admin) throws Exception {
diff --git a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropSetCommand.java b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropSetCommand.java
index e617d1b..d8a12ea 100644
--- a/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropSetCommand.java
+++ b/karaf/shell/config/src/main/java/org/apache/felix/karaf/shell/config/PropSetCommand.java
@@ -22,13 +22,13 @@
import org.apache.felix.gogo.commands.Command;
import org.osgi.service.cm.ConfigurationAdmin;
-@Command(scope = "config", name = "propset", description = "Set a property on the edited configuration.")
+@Command(scope = "config", name = "propset", description = "Sets a property in the currently edited configuration.")
public class PropSetCommand extends ConfigCommandSupport {
- @Argument(index = 0, required = true, description = "the property to set")
+ @Argument(index = 0, name = "property", description = "The name of the property to set", required = true, multiValued = false)
String prop;
- @Argument(index = 1, required = true, description = "the value of the property")
+ @Argument(index = 1, name = "value", description = "The value of the property", required = true, multiValued = false)
String value;
protected void doExecute(ConfigurationAdmin admin) throws Exception {
diff --git a/karaf/shell/console/src/main/filtered-resources/org/apache/felix/karaf/shell/console/branding.properties b/karaf/shell/console/src/main/filtered-resources/org/apache/felix/karaf/shell/console/branding.properties
index 090f396..917d5b3 100644
--- a/karaf/shell/console/src/main/filtered-resources/org/apache/felix/karaf/shell/console/branding.properties
+++ b/karaf/shell/console/src/main/filtered-resources/org/apache/felix/karaf/shell/console/branding.properties
@@ -27,7 +27,7 @@
\u001B[1m Apache Felix Karaf\u001B[0m (${pom.version})\n\
\n\
Hit '\u001B[1m<tab>\u001B[0m' for a list of available commands\n\
- and '\u001B[1m[cmd] --help\u001B[0m' for help on a specific command.\n
-
+ and '\u001B[1m[cmd] --help\u001B[0m' for help on a specific command.\n\
+Hit '\u001B[1m<ctrl-d>\u001B[0m' or '\u001B[1mosgi:shutdown\u001B[0m' to shutdown Karaf.\n
diff --git a/karaf/shell/console/src/main/java/org/apache/felix/karaf/shell/console/commands/BlueprintCommand.java b/karaf/shell/console/src/main/java/org/apache/felix/karaf/shell/console/commands/BlueprintCommand.java
index 80e3b4c..b40f415 100644
--- a/karaf/shell/console/src/main/java/org/apache/felix/karaf/shell/console/commands/BlueprintCommand.java
+++ b/karaf/shell/console/src/main/java/org/apache/felix/karaf/shell/console/commands/BlueprintCommand.java
@@ -86,7 +86,7 @@
{
options = new HashSet<Option>(options);
options.add(HELP);
- if (command != null && (command.description() != null) || command.name() != null)
+ if (command != null && (command.description() != null || command.name() != null))
{
out.println(Ansi.ansi().a(Ansi.Attribute.INTENSITY_BOLD).a("DESCRIPTION").a(Ansi.Attribute.RESET));
out.print("\t");
@@ -98,47 +98,41 @@
out.println(command.description());
out.println();
}
- String syntax = "";
+ StringBuffer syntax = new StringBuffer();
if (command != null)
{
- syntax += command.scope() + ":" + command.name();
+ syntax.append(String.format("%s:%s", command.scope(), command.name()));
}
if (options.size() > 0)
{
- syntax += " [options]";
+ syntax.append(" [options]");
}
if (arguments.size() > 0)
{
- if (arguments.size() > 0) {
- syntax += " ";
- }
+ syntax.append(' ');
for (Argument argument : arguments)
{
- if (argument.required())
+ if (!argument.required())
{
- syntax += "[" + argument.name() + "]";
+ syntax.append(String.format("[%s] ", argument.name()));
}
else
{
- syntax += argument.name();
+ syntax.append(String.format("%s ", argument.name()));
}
}
}
out.println(Ansi.ansi().a(Ansi.Attribute.INTENSITY_BOLD).a("SYNTAX").a(Ansi.Attribute.RESET));
out.print("\t");
- out.println(syntax);
+ out.println(syntax.toString());
out.println();
if (arguments.size() > 0)
{
out.println(Ansi.ansi().a(Ansi.Attribute.INTENSITY_BOLD).a("ARGUMENTS").a(Ansi.Attribute.RESET));
for (Argument argument : arguments)
{
- out.print("\t");
- out.print(argument.name());
- out.print("\t");
- out.print(argument.description());
- out.println();
+ out.println(String.format("\t%-15s%s", argument.name(), argument.description()));
}
out.println();
}
@@ -154,9 +148,7 @@
}
out.print("\t");
out.println(opt);
- out.print("\t\t");
- out.print(option.description());
- out.println();
+ out.println(String.format("\t%-15s%s", "", option.description()));
}
out.println();
}
diff --git a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayException.java b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayException.java
index a0224ef..314adca 100644
--- a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayException.java
+++ b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayException.java
@@ -20,7 +20,7 @@
import org.apache.felix.karaf.shell.console.OsgiCommandSupport;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "log", name = "display-exception", description = "Display the last exception from the log.")
+@Command(scope = "log", name = "display-exception", description = "Displays the last occured exception from the log.")
public class DisplayException extends OsgiCommandSupport {
protected LruList events;
diff --git a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayLog.java b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayLog.java
index 2baf45b..ee62ef7 100644
--- a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayLog.java
+++ b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/DisplayLog.java
@@ -26,17 +26,16 @@
/**
* Displays the last log entries
*/
-@Command(scope = "log", name = "display", description = "Display log entries.")
+@Command(scope = "log", name = "display", description = "Displays log entries.")
public class DisplayLog extends OsgiCommandSupport {
- @Option(name = "-n", description="Number of entries to display")
+ @Option(name = "-n", aliases = {}, description="Number of entries to display", required = false, multiValued = false)
protected int entries;
- @Option(name = "-p", description="Output formatting pattern")
+ @Option(name = "-p", aliases = {}, description="Pattern for formatting the output", required = false, multiValued = false)
protected String overridenPattern;
protected String pattern;
-
protected LruList events;
public LruList getEvents() {
diff --git a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/GetLogLevel.java b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/GetLogLevel.java
index b0873b2..618affe 100644
--- a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/GetLogLevel.java
+++ b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/GetLogLevel.java
@@ -31,10 +31,10 @@
/**
* Get the log level for a given logger
*/
-@Command(scope = "log", name = "get", description = "Show log level.")
+@Command(scope = "log", name = "get", description = "Shows the currently set log level.")
public class GetLogLevel extends OsgiCommandSupport {
- @Argument(required = false, name = "LOGGER", description = "Logger name, ALL or ROOT (default)")
+ @Argument(index = 0, name = "logger", description = "The name of the logger, ALL or ROOT (default)", required = false, multiValued = false)
String logger;
static final String CONFIGURATION_PID = "org.ops4j.pax.logging";
diff --git a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/SetLogLevel.java b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/SetLogLevel.java
index 48c8b63..d8d683e 100644
--- a/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/SetLogLevel.java
+++ b/karaf/shell/log/src/main/java/org/apache/felix/karaf/shell/log/SetLogLevel.java
@@ -28,13 +28,13 @@
/**
* Set the log level for a given logger
*/
-@Command(scope = "log", name = "set", description = "Set the log level.")
+@Command(scope = "log", name = "set", description = "Sets the log level.")
public class SetLogLevel extends OsgiCommandSupport {
- @Argument(index = 0, required = true, name = "LEVEL", description = "Level (TRACE, DEBUG, INFO, WARN, ERROR or - to unset")
+ @Argument(index = 0, name = "level", description = "The log level to set (TRACE, DEBUG, INFO, WARN, ERROR or - to unset)", required = true, multiValued = false)
String level;
- @Argument(index = 1, required = false, name = "LOGGER", description = "Logger name or ROOT (default)")
+ @Argument(index = 1, name = "logger", description = "Logger name or ROOT (default)", required = false, multiValued = false)
String logger;
static final String CONFIGURATION_PID = "org.ops4j.pax.logging";
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/AddUrlCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/AddUrlCommand.java
index 18a4c4b..e1ac172 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/AddUrlCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/AddUrlCommand.java
@@ -23,10 +23,10 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "obr", name = "addUrl", description = "Add a list of repository URLs to the OBR service.")
+@Command(scope = "obr", name = "addUrl", description = "Adds a list of repository URLs to the OBR service.")
public class AddUrlCommand extends ObrCommandSupport {
- @Argument(required = true, multiValued = true, description = "Repository URLs")
+ @Argument(index = 0, name = "urls", description = "Repository URLs to add to the OBR service separated by whitespaces", required = true, multiValued = true)
List<String> urls;
protected void doExecute(RepositoryAdmin admin) throws Exception {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/DeployCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/DeployCommand.java
index 37cd146..c2bf6e3 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/DeployCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/DeployCommand.java
@@ -22,10 +22,10 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "obr", name = "deploy", description = "Deploy a list of bundles using OBR")
+@Command(scope = "obr", name = "deploy", description = "Deploys a list of bundles using OBR service")
public class DeployCommand extends ObrCommandSupport {
- @Argument(required = true, multiValued = true, description = "List of bundles")
+ @Argument(index = 0, name = "bundles", description = "List of bundle names to deploy (separated by whitespaces)", required = true, multiValued = true)
protected List<String> bundles;
protected void doExecute(RepositoryAdmin admin) throws Exception {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/InfoCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/InfoCommand.java
index ab50497..493460c 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/InfoCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/InfoCommand.java
@@ -29,10 +29,10 @@
import org.osgi.service.obr.Requirement;
import org.osgi.service.obr.Resource;
-@Command(scope = "obr", name = "info", description = "Print informations about OBR bundles")
+@Command(scope = "obr", name = "info", description = "Prints information about OBR bundles")
public class InfoCommand extends ObrCommandSupport {
- @Argument(required = true, multiValued = true)
+ @Argument(index = 0, name = "bundles", description = "Specify bundles to query for information (separated by whitespaces)", required = true, multiValued = true)
List<String> bundles;
protected void doExecute(RepositoryAdmin admin) throws Exception {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListCommand.java
index 7a43565..b2e1185 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListCommand.java
@@ -24,10 +24,10 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "obr", name = "list", description = "List OBR bundles")
+@Command(scope = "obr", name = "list", description = "Lists OBR bundles")
public class ListCommand extends ObrCommandSupport {
- @Argument(required = false, multiValued = true)
+ @Argument(index = 0, name = "args", description = "The arguments", required = false, multiValued = true)
List<String> args;
protected void doExecute(RepositoryAdmin admin) throws Exception {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListUrlCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListUrlCommand.java
index ee071b1..e66c9e8 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListUrlCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/ListUrlCommand.java
@@ -20,7 +20,7 @@
import org.osgi.service.obr.RepositoryAdmin;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "obr", name = "listUrl", description = "Display the repository URLs currently associated with the OBR service.")
+@Command(scope = "obr", name = "listUrl", description = "Displays the repository URLs currently associated with the OBR service.")
public class ListUrlCommand extends ObrCommandSupport {
protected void doExecute(RepositoryAdmin admin) {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RefreshUrlCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RefreshUrlCommand.java
index 0a3dd4d..a4d7e2e 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RefreshUrlCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RefreshUrlCommand.java
@@ -24,13 +24,12 @@
import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
-@Command(scope = "obr", name = "refreshUrl", description = "Reload the repositories to obtain a fresh list of bundles.")
+@Command(scope = "obr", name = "refreshUrl", description = "Reloads the repositories to obtain a fresh list of bundles.")
public class RefreshUrlCommand extends ObrCommandSupport {
- @Argument(required = false, multiValued = true, description = "Repository URLs (leave empty for all)")
+ @Argument(index = 0, name = "urls", description = "Repository URLs to refresh (leave empty for all)", required = false, multiValued = true)
List<String> urls;
-
protected void doExecute(RepositoryAdmin admin) throws Exception {
if (urls != null || urls.isEmpty()) {
for (String url : urls) {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RemoveUrlCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RemoveUrlCommand.java
index 5c307dd..452a6da 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RemoveUrlCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/RemoveUrlCommand.java
@@ -23,10 +23,10 @@
import org.apache.felix.gogo.commands.Command;
import org.osgi.service.obr.RepositoryAdmin;
-@Command(scope = "obr", name = "removeUrl", description = "Remove a list of repository URLs from the OBR service.")
+@Command(scope = "obr", name = "removeUrl", description = "Removes a list of repository URLs from the OBR service.")
public class RemoveUrlCommand extends ObrCommandSupport {
- @Argument(required = true, multiValued = true, description = "Repository URLs")
+ @Argument(index = 0, name = "urls", description = "Repository URLs to remove from OBR service", required = true, multiValued = true)
List<String> urls;
protected void doExecute(RepositoryAdmin admin) throws Exception {
diff --git a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/SourceCommand.java b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/SourceCommand.java
index 12e28d3..0c81967 100644
--- a/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/SourceCommand.java
+++ b/karaf/shell/obr/src/main/java/org/apache/felix/karaf/shell/obr/SourceCommand.java
@@ -28,13 +28,13 @@
@Command(scope = "obr", name = "source", description = "Download the sources for an OBR bundle.")
public class SourceCommand extends ObrCommandSupport {
- @Option(name = "-x", description = "Extract")
+ @Option(name = "-x", aliases = {}, description = "Extract the archive", required = false, multiValued = false)
boolean extract;
- @Argument(required = true, index = 0, description = "Local directory")
+ @Argument(index = 0, name = "folder", description = "Local folder for storing sources", required = true, multiValued = false)
String localDir;
- @Argument(required = true, index = 1, multiValued = true, description = "List of bundles")
+ @Argument(index = 1, name = "bundles", description = "List of bundles to download the sources for", required = true, multiValued = true)
List<String> bundles;
protected void doExecute(RepositoryAdmin admin) throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleCommand.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleCommand.java
index ae66f9f..f5f074d 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleCommand.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleCommand.java
@@ -23,10 +23,10 @@
public abstract class BundleCommand extends OsgiCommandSupport {
- @Argument(required = true, index = 0)
+ @Argument(index = 0, name = "id", description = "The bundle ID", required = true, multiValued = false)
long id;
- @Option(name = "--force")
+ @Option(name = "--force", aliases = {}, description = "Forces the command to execute", required = false, multiValued = false)
boolean force;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleLevel.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleLevel.java
index fb27683..3eca185 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleLevel.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundleLevel.java
@@ -25,7 +25,7 @@
@Command(scope = "osgi", name = "bundle-level", description = "Get or set the start level of a given bundle")
public class BundleLevel extends BundleCommand {
- @Argument(required = false, index = 1)
+ @Argument(index = 1, name = "startLevel", description = "The bundles new start level", required = false, multiValued = false)
Integer level;
protected void doExecute(Bundle bundle) throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundlesCommand.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundlesCommand.java
index 887304c..f2bee4d 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundlesCommand.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/BundlesCommand.java
@@ -26,10 +26,10 @@
public abstract class BundlesCommand extends OsgiCommandSupport {
- @Argument(required = true, multiValued = true, description = "Bundle IDs")
+ @Argument(index = 0, name = "ids", description = "The list of bundle IDs separated by whitespaces", required = true, multiValued = true)
List<Long> ids;
- @Option(name = "--force")
+ @Option(name = "--force", aliases = {}, description = "Forces the command to execute", required = false, multiValued = false)
boolean force;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Headers.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Headers.java
index cf17ede..712a968 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Headers.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Headers.java
@@ -25,10 +25,10 @@
import org.apache.felix.gogo.commands.Command;
import org.osgi.framework.Bundle;
-@Command(scope = "osgi", name = "headers", description = "Display OSGi headers of a given bundle")
+@Command(scope = "osgi", name = "headers", description = "Displays OSGi headers of a given bundle")
public class Headers extends OsgiCommandSupport {
- @Argument(required = false, multiValued = true, description = "Bundles ids")
+ @Argument(index = 0, name = "ids", description = "A list of bundle IDs separated by whitespaces", required = false, multiValued = true)
List<Long> ids;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/InstallBundle.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/InstallBundle.java
index 6061006..c777b51 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/InstallBundle.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/InstallBundle.java
@@ -27,13 +27,13 @@
import org.osgi.framework.Bundle;
import org.osgi.framework.BundleException;
-@Command(scope = "osgi", name = "install", description = "Install bundle(s)")
+@Command(scope = "osgi", name = "install", description = "Installs one or more bundles")
public class InstallBundle extends OsgiCommandSupport {
- @Argument(required = true, multiValued = true, description = "Bundle URLs")
+ @Argument(index = 0, name = "urls", description = "Bundle URLs separated by whitespaces", required = true, multiValued = true)
List<String> urls;
- @Option(name = "-s", aliases={"--start"}, description="Start the bundles after installation")
+ @Option(name = "-s", aliases={"--start"}, description="Starts the bundles after installation", required = false, multiValued = false)
boolean start;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListBundles.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListBundles.java
index 7844bb1..523ec00 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListBundles.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListBundles.java
@@ -27,16 +27,16 @@
import org.osgi.service.packageadmin.PackageAdmin;
import org.osgi.service.startlevel.StartLevel;
-@Command(scope = "osgi", name = "list", description = "List bundles")
+@Command(scope = "osgi", name = "list", description = "Lists all installed bundles")
public class ListBundles extends OsgiCommandSupport {
- @Option(name = "-l", description = "Show locations")
+ @Option(name = "-l", aliases = {}, description = "Show the locations", required = false, multiValued = false)
boolean showLoc;
- @Option(name = "-s", description = "Show symbolic name")
+ @Option(name = "-s", description = "Shows the symbolic name", required = false, multiValued = false)
boolean showSymbolic;
- @Option(name = "-u", description = "Show update")
+ @Option(name = "-u", description = "Shows the update locations", required = false, multiValued = false)
boolean showUpdate;
private List<BundleStateListener.Factory> bundleStateListenerFactories;
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListServices.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListServices.java
index 0c36909..8685df7 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListServices.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/ListServices.java
@@ -26,16 +26,16 @@
import org.osgi.framework.ServiceReference;
import org.osgi.service.command.Function;
-@Command(scope = "osgi", name = "ls", description = "List services")
+@Command(scope = "osgi", name = "ls", description = "Lists OSGi services")
public class ListServices extends OsgiCommandSupport {
- @Option(name = "-a", description = "Show all")
+ @Option(name = "-a", aliases = {}, description = "Shows all services", required = false, multiValued = false)
boolean showAll;
- @Option(name = "-u", description = "Show in use")
+ @Option(name = "-u", aliases = {}, description = "Shows services which are in use", required = false, multiValued = false)
boolean inUse;
- @Argument(required = false, multiValued = true, description = "Bundles ids")
+ @Argument(index = 0, name = "ids", description = "Show only services for the given bundle ids", required = false, multiValued = true)
List<Long> ids;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/RefreshBundle.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/RefreshBundle.java
index 581070a..33f1db5 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/RefreshBundle.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/RefreshBundle.java
@@ -23,10 +23,10 @@
import org.osgi.framework.ServiceReference;
import org.osgi.service.packageadmin.PackageAdmin;
-@Command(scope = "osgi", name = "refresh", description = "Refresh bundle(s)")
+@Command(scope = "osgi", name = "refresh", description = "Refresh a bundle")
public class RefreshBundle extends OsgiCommandSupport {
- @Argument(required = false)
+ @Argument(index = 0, name = "id", description = "The ID of the bundle to refresh", required = false, multiValued = false)
Long id;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Shutdown.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Shutdown.java
index 9298ef5..12d364b 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Shutdown.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/Shutdown.java
@@ -23,7 +23,7 @@
/**
* Command to shut down Karaf
*/
-@Command(scope = "osgi", name = "shutdown", description = "Shut the framework down")
+@Command(scope = "osgi", name = "shutdown", description = "Shuts the framework down")
public class Shutdown extends OsgiCommandSupport {
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/StartLevel.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/StartLevel.java
index 8e7c3e3..d266422 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/StartLevel.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/StartLevel.java
@@ -21,10 +21,10 @@
import org.apache.felix.gogo.commands.Command;
import org.osgi.framework.ServiceReference;
-@Command(scope = "osgi", name = "start-level", description = "Get or set the start level")
+@Command(scope = "osgi", name = "start-level", description = "Get or set the system start level")
public class StartLevel extends OsgiCommandSupport {
- @Argument(required = false, index = 0)
+ @Argument(index = 0, name = "level", description = "The new system start level to set", required = false, multiValued = false)
Integer level;
protected Object doExecute() throws Exception {
diff --git a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/UpdateBundle.java b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/UpdateBundle.java
index 8accc56..6ee1a0a 100644
--- a/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/UpdateBundle.java
+++ b/karaf/shell/osgi/src/main/java/org/apache/felix/karaf/shell/osgi/UpdateBundle.java
@@ -26,7 +26,7 @@
@Command(scope = "osgi", name = "update", description = "Update bundle")
public class UpdateBundle extends BundleCommand {
- @Argument(required = false, description = "Bundle location", index=1)
+ @Argument(index = 1, name = "location", description = "The bundles update location", required = false, multiValued = false)
String location;
protected void doExecute(Bundle bundle) throws Exception {
diff --git a/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ExportsCommand.java b/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ExportsCommand.java
index 96ae308..f823d7e 100644
--- a/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ExportsCommand.java
+++ b/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ExportsCommand.java
@@ -30,10 +30,10 @@
@Command(scope = "packages", name = "exports", description = "Display exported packages")
public class ExportsCommand extends PackageCommandSupport {
- @Option(name = "-i", aliases = { "--imports"}, description = "List bundles importing the packages")
+ @Option(name = "-i", aliases = { "--imports"}, description = "List bundles importing the specified packages")
boolean imports;
- @Argument(required = false, multiValued = true, description = "bundle ids")
+ @Argument(index = 0, name = "ids", description = "The IDs of bundles to check", required = false, multiValued = true)
List<Long> ids;
protected void doExecute(PackageAdmin admin) throws Exception {
diff --git a/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ImportsCommand.java b/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ImportsCommand.java
index f2d9733..ab423f3 100644
--- a/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ImportsCommand.java
+++ b/karaf/shell/packages/src/main/java/org/apache/felix/karaf/shell/packages/ImportsCommand.java
@@ -32,7 +32,7 @@
@Command(scope = "packages", name = "imports", description = "Display imported packages")
public class ImportsCommand extends PackageCommandSupport {
- @Argument(required = false, multiValued = true, description = "bundle ids")
+ @Argument(index = 0, name = "ids", description = "The IDs of bundles to check", required = false, multiValued = true)
List<Long> ids;
protected void doExecute(PackageAdmin admin) throws Exception {
diff --git a/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshAction.java b/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshAction.java
index a9e165f..018130a 100644
--- a/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshAction.java
+++ b/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshAction.java
@@ -41,22 +41,22 @@
*
* @version $Rev: 721244 $ $Date: 2008-11-27 18:19:56 +0100 (Thu, 27 Nov 2008) $
*/
-@Command(scope = "ssh", name = "ssh", description = "Connect to a remote SSH server")
+@Command(scope = "ssh", name = "ssh", description = "Connects to a remote SSH server")
public class SshAction
extends OsgiCommandSupport implements BlueprintContainerAware
{
private final Logger log = LoggerFactory.getLogger(getClass());
- @Option(name="-l", aliases={"--username"}, description = "Username")
+ @Option(name="-l", aliases={"--username"}, description = "The user name for remote login", required = false, multiValued = false)
private String username;
- @Option(name="-P", aliases={"--password"}, description = "Password")
+ @Option(name="-P", aliases={"--password"}, description = "The password for remote login", required = false, multiValued = false)
private String password;
- @Argument(required=true, description = "Host")
+ @Argument(index = 0, name = "hostname", description = "The host name to connect to via SSH", required = true, multiValued = false)
private String hostname;
- @Option(name="-p", aliases={"--port"}, description = "Port")
+ @Option(name="-p", aliases={"--port"}, description = "The port to use for SSH connection", required = false, multiValued = false)
private int port = 22;
private BlueprintContainer container;
diff --git a/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshServerAction.java b/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshServerAction.java
index a67eaf7..4d02a6c 100644
--- a/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshServerAction.java
+++ b/karaf/shell/ssh/src/main/java/org/apache/felix/karaf/shell/ssh/SshServerAction.java
@@ -33,15 +33,15 @@
*
* @version $Rev: 720411 $ $Date: 2008-11-25 05:32:43 +0100 (Tue, 25 Nov 2008) $
*/
-@Command(scope = "ssh", name = "sshd", description = "Create an SSH server")
+@Command(scope = "ssh", name = "sshd", description = "Creates a SSH server")
public class SshServerAction extends OsgiCommandSupport implements BlueprintContainerAware
{
private final Logger log = LoggerFactory.getLogger(getClass());
- @Option(name="-p", aliases={ "--port" }, description = "Port")
+ @Option(name="-p", aliases={ "--port" }, description = "The port to setup the SSH server (Default: 8101)", required = false, multiValued = false)
private int port = 8101;
- @Option(name="-b", aliases={ "--background"}, description = "Background")
+ @Option(name="-b", aliases={ "--background"}, description = "The service will run in the background (Default: true)", required = false, multiValued = false)
private boolean background = true;
private BlueprintContainer container;
diff --git a/karaf/shell/wrapper/src/main/java/org/apache/felix/karaf/shell/wrapper/InstallCommand.java b/karaf/shell/wrapper/src/main/java/org/apache/felix/karaf/shell/wrapper/InstallCommand.java
index 77ae201..2aeeb5d 100644
--- a/karaf/shell/wrapper/src/main/java/org/apache/felix/karaf/shell/wrapper/InstallCommand.java
+++ b/karaf/shell/wrapper/src/main/java/org/apache/felix/karaf/shell/wrapper/InstallCommand.java
@@ -36,20 +36,19 @@
*
* @version $Rev: 603634 $ $Date: 2007-12-12 16:07:16 +0100 (Wed, 12 Dec 2007) $
*/
-@Command(scope = "wrapper", name = "install", description = "Install Karaf as a system service in the OS.")
+@Command(scope = "wrapper", name = "install", description = "Install the container as a system service in the OS.")
public class InstallCommand extends OsgiCommandSupport
{
-
- @Option(name="-n", aliases={"--name"}, description="The service name that will be used when installing the service.")
+ @Option(name="-n", aliases={"--name"}, description="The service name that will be used when installing the service. (Default: karaf)", required = false, multiValued = false)
private String name="karaf";
- @Option(name="-d", aliases={"--display"}, description="The display name of the service.")
+ @Option(name="-d", aliases={"--display"}, description="The display name of the service.", required = false, multiValued = false)
private String displayName;
- @Option(name="-D", aliases={"--description"}, description="The description of the service.")
+ @Option(name="-D", aliases={"--description"}, description="The description of the service.", required = false, multiValued = false)
private String description="";
- @Option(name="-s", aliases={"--start-type"}, description="Mode in which the service is installed. AUTO_START or DEMAND_START")
+ @Option(name="-s", aliases={"--start-type"}, description="Mode in which the service is installed. AUTO_START or DEMAND_START (Default: AUTO_START)", required = false, multiValued = false)
private String startType="AUTO_START";
protected Object doExecute() throws Exception {