From e48922915389e2b440fd87cc4b3f100be04be4ba Mon Sep 17 00:00:00 2001 From: joshrosso Date: Tue, 25 Oct 2016 17:12:15 -0700 Subject: [PATCH] etcdctl: add ttl unit to flag description Add the ttl unit (seconds) to --ttl description for etcdctl's mk, mkdir, set, setdir, update, and updatedir commands. --- etcdctl/ctlv2/command/mk_command.go | 2 +- etcdctl/ctlv2/command/mkdir_command.go | 2 +- etcdctl/ctlv2/command/set_command.go | 2 +- etcdctl/ctlv2/command/set_dir_command.go | 2 +- etcdctl/ctlv2/command/update_command.go | 2 +- etcdctl/ctlv2/command/update_dir_command.go | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/etcdctl/ctlv2/command/mk_command.go b/etcdctl/ctlv2/command/mk_command.go index aeb40933b..73dad0bf5 100644 --- a/etcdctl/ctlv2/command/mk_command.go +++ b/etcdctl/ctlv2/command/mk_command.go @@ -31,7 +31,7 @@ func NewMakeCommand() cli.Command { ArgsUsage: " ", Flags: []cli.Flag{ cli.BoolFlag{Name: "in-order", Usage: "create in-order key under directory "}, - cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live"}, + cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live in seconds"}, }, Action: func(c *cli.Context) error { mkCommandFunc(c, mustNewKeyAPI(c)) diff --git a/etcdctl/ctlv2/command/mkdir_command.go b/etcdctl/ctlv2/command/mkdir_command.go index 7d2c6779c..a3babb9ae 100644 --- a/etcdctl/ctlv2/command/mkdir_command.go +++ b/etcdctl/ctlv2/command/mkdir_command.go @@ -29,7 +29,7 @@ func NewMakeDirCommand() cli.Command { Usage: "make a new directory", ArgsUsage: "", Flags: []cli.Flag{ - cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live"}, + cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live in seconds"}, }, Action: func(c *cli.Context) error { mkdirCommandFunc(c, mustNewKeyAPI(c), client.PrevNoExist) diff --git a/etcdctl/ctlv2/command/set_command.go b/etcdctl/ctlv2/command/set_command.go index c9d332c39..130a6c13a 100644 --- a/etcdctl/ctlv2/command/set_command.go +++ b/etcdctl/ctlv2/command/set_command.go @@ -36,7 +36,7 @@ func NewSetCommand() cli.Command { $ set -- `, Flags: []cli.Flag{ - cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live"}, + cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live in seconds"}, cli.StringFlag{Name: "swap-with-value", Value: "", Usage: "previous value"}, cli.IntFlag{Name: "swap-with-index", Value: 0, Usage: "previous index"}, }, diff --git a/etcdctl/ctlv2/command/set_dir_command.go b/etcdctl/ctlv2/command/set_dir_command.go index b770684e2..aba66b089 100644 --- a/etcdctl/ctlv2/command/set_dir_command.go +++ b/etcdctl/ctlv2/command/set_dir_command.go @@ -26,7 +26,7 @@ func NewSetDirCommand() cli.Command { Usage: "create a new directory or update an existing directory TTL", ArgsUsage: "", Flags: []cli.Flag{ - cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live"}, + cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live in seconds"}, }, Action: func(c *cli.Context) error { mkdirCommandFunc(c, mustNewKeyAPI(c), client.PrevIgnore) diff --git a/etcdctl/ctlv2/command/update_command.go b/etcdctl/ctlv2/command/update_command.go index 947eaa922..8ab9fb4af 100644 --- a/etcdctl/ctlv2/command/update_command.go +++ b/etcdctl/ctlv2/command/update_command.go @@ -30,7 +30,7 @@ func NewUpdateCommand() cli.Command { Usage: "update an existing key with a given value", ArgsUsage: " ", Flags: []cli.Flag{ - cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live"}, + cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live in seconds"}, }, Action: func(c *cli.Context) error { updateCommandFunc(c, mustNewKeyAPI(c)) diff --git a/etcdctl/ctlv2/command/update_dir_command.go b/etcdctl/ctlv2/command/update_dir_command.go index 650674a6f..1cc4e087c 100644 --- a/etcdctl/ctlv2/command/update_dir_command.go +++ b/etcdctl/ctlv2/command/update_dir_command.go @@ -29,7 +29,7 @@ func NewUpdateDirCommand() cli.Command { Usage: "update an existing directory", ArgsUsage: " ", Flags: []cli.Flag{ - cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live"}, + cli.IntFlag{Name: "ttl", Value: 0, Usage: "key time-to-live in seconds"}, }, Action: func(c *cli.Context) error { updatedirCommandFunc(c, mustNewKeyAPI(c))