Browse code

update secret command

Signed-off-by: erxian <evelynhsu21@gmail.com>

erxian authored on 2016/11/18 15:28:21
Showing 5 changed files
... ...
@@ -25,7 +25,7 @@ func newSecretCreateCommand(dockerCli *command.DockerCli) *cobra.Command {
25 25
 	}
26 26
 
27 27
 	cmd := &cobra.Command{
28
-		Use:   "create [name]",
28
+		Use:   "create [OPTIONS] SECRET [SECRET...]",
29 29
 		Short: "Create a secret using stdin as content",
30 30
 		Args:  cli.RequiresMinArgs(1),
31 31
 		RunE: func(cmd *cobra.Command, args []string) error {
... ...
@@ -16,8 +16,8 @@ type inspectOptions struct {
16 16
 func newSecretInspectCommand(dockerCli *command.DockerCli) *cobra.Command {
17 17
 	opts := inspectOptions{}
18 18
 	cmd := &cobra.Command{
19
-		Use:   "inspect SECRET [SECRET]",
20
-		Short: "Inspect a secret",
19
+		Use:   "inspect [OPTIONS] SECRET [SECRET...]",
20
+		Short: "Display detailed information on one or more secrets",
21 21
 		Args:  cli.RequiresMinArgs(1),
22 22
 		RunE: func(cmd *cobra.Command, args []string) error {
23 23
 			opts.names = args
... ...
@@ -21,7 +21,7 @@ func newSecretListCommand(dockerCli *command.DockerCli) *cobra.Command {
21 21
 	opts := listOptions{}
22 22
 
23 23
 	cmd := &cobra.Command{
24
-		Use:   "ls",
24
+		Use:   "ls [OPTIONS]",
25 25
 		Short: "List secrets",
26 26
 		Args:  cli.NoArgs,
27 27
 		RunE: func(cmd *cobra.Command, args []string) error {
... ...
@@ -15,8 +15,8 @@ type removeOptions struct {
15 15
 
16 16
 func newSecretRemoveCommand(dockerCli *command.DockerCli) *cobra.Command {
17 17
 	return &cobra.Command{
18
-		Use:   "rm SECRET [SECRET]",
19
-		Short: "Remove a secret",
18
+		Use:   "rm SECRET [SECRET...]",
19
+		Short: "Remove one or more secrets",
20 20
 		Args:  cli.RequiresMinArgs(1),
21 21
 		RunE: func(cmd *cobra.Command, args []string) error {
22 22
 			opts := removeOptions{
... ...
@@ -16,7 +16,7 @@ keywords: ["secret, create"]
16 16
 # secret create
17 17
 
18 18
 ```Markdown
19
-Usage:  docker secret create [NAME]
19
+Usage:  docker secret create [OPTIONS] SECRET
20 20
 
21 21
 Create a secret using stdin as content
22 22
 Options:
... ...
@@ -76,5 +76,3 @@ $ docker secret inspect secret.json
76 76
 * [secret inspect](secret_inspect.md)
77 77
 * [secret ls](secret_ls.md)
78 78
 * [secret rm](secret_rm.md)
79
-
80
-<style>table tr > td:first-child { white-space: nowrap;}</style>