Skip to content

Commit

Permalink
command: use ':' instead of ',' in error msg
Browse files Browse the repository at this point in the history
  • Loading branch information
nickethier committed Apr 18, 2018
1 parent 4a4ed06 commit 0216a8e
Show file tree
Hide file tree
Showing 34 changed files with 34 additions and 34 deletions.
2 changes: 1 addition & 1 deletion command/acl_policy_apply.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func (c *ACLPolicyApplyCommand) Run(args []string) int {
// Check that we got two arguments
args = flags.Args()
if l := len(args); l != 2 {
c.Ui.Error("This command takes two arguments, <name> and <path>")
c.Ui.Error("This command takes two arguments: <name> and <path>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/acl_policy_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (c *ACLPolicyDeleteCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <name>")
c.Ui.Error("This command takes one argument: <name>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/acl_policy_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (c *ACLPolicyInfoCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <name>")
c.Ui.Error("This command takes one argument: <name>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/acl_token_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ func (c *ACLTokenDeleteCommand) Run(args []string) int {
// such token was provided.
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <token_accessor_id>")
c.Ui.Error("This command takes one argument: <token_accessor_id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/acl_token_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (c *ACLTokenInfoCommand) Run(args []string) int {
// Check that we have exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <token_accessor_id>")
c.Ui.Error("This command takes one argument: <token_accessor_id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/acl_token_update.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func (c *ACLTokenUpdateCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <token_accessor_id>")
c.Ui.Error("This command takes one argument: <token_accessor_id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/alloc_fs.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ func (f *AllocFSCommand) Run(args []string) int {
}

if len(args) > 2 {
f.Ui.Error("This command takes one or two arguments, <allocation> [<path>]")
f.Ui.Error("This command takes one or two arguments: <allocation> [<path>]")
f.Ui.Error(commandErrorText(f))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/deployment_pause.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ func (c *DeploymentPauseCommand) Run(args []string) int {
// Check that we got exactly 1 argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <deployment id>")
c.Ui.Error("This command takes one argument: <deployment id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/deployment_promote.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func (c *DeploymentPromoteCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <deployment id>")
c.Ui.Error("This command takes one argument: <deployment id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/deployment_resume.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func (c *DeploymentResumeCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <deployment id>")
c.Ui.Error("This command takes one argument: <deployment id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/deployment_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func (c *DeploymentStatusCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <deployment id>")
c.Ui.Error("This command takes one argument: <deployment id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_deployments.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ func (c *JobDeploymentsCommand) Run(args []string) int {
// Check that we got exactly one node
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <job>")
c.Ui.Error("This command takes one argument: <job>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_dispatch.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ func (c *JobDispatchCommand) Run(args []string) int {
// Check that we got exactly one node
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <parameterized job>")
c.Ui.Error("This command takes one argument: <parameterized job>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_history.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func (c *JobHistoryCommand) Run(args []string) int {
// Check that we got exactly one node
args = flags.Args()
if l := len(args); l < 1 || l > 2 {
c.Ui.Error("This command takes one argument, <job>")
c.Ui.Error("This command takes one argument: <job>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_inspect.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ func (c *JobInspectCommand) Run(args []string) int {

// Check that we got exactly one job
if len(args) != 1 {
c.Ui.Error("This command takes one argument, <job>")
c.Ui.Error("This command takes one argument: <job>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_plan.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ func (c *JobPlanCommand) Run(args []string) int {
// Check that we got exactly one job
args = flags.Args()
if len(args) != 1 {
c.Ui.Error("This command takes one argument, <path>")
c.Ui.Error("This command takes one argument: <path>")
c.Ui.Error(commandErrorText(c))
return 255
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_promote.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ func (c *JobPromoteCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <job id>")
c.Ui.Error("This command takes one argument: <job id>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_revert.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func (c *JobRevertCommand) Run(args []string) int {
// Check that we got two args
args = flags.Args()
if l := len(args); l != 2 {
c.Ui.Error("This command takes two arguments, <job> <version>")
c.Ui.Error("This command takes two arguments: <job> <version>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_run.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ func (c *JobRunCommand) Run(args []string) int {
// Check that we got exactly one argument
args = flags.Args()
if len(args) != 1 {
c.Ui.Error("This command takes one argument, <path>")
c.Ui.Error("This command takes one argument: <path>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func (c *JobStatusCommand) Run(args []string) int {
// Check that we either got no jobs or exactly one.
args = flags.Args()
if len(args) > 1 {
c.Ui.Error("This command takes either no arguments or one, <job>")
c.Ui.Error("This command takes either no arguments or one: <job>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_stop.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ func (c *JobStopCommand) Run(args []string) int {
// Check that we got exactly one job
args = flags.Args()
if len(args) != 1 {
c.Ui.Error("This command takes one argument, <job>")
c.Ui.Error("This command takes one argument: <job>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/job_validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ func (c *JobValidateCommand) Run(args []string) int {
// Check that we got exactly one node
args = flags.Args()
if len(args) != 1 {
c.Ui.Error("This command takes one argument, <path>")
c.Ui.Error("This command takes one argument: <path>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/namespace_apply.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func (c *NamespaceApplyCommand) Run(args []string) int {
// Check that we get exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <namespace>")
c.Ui.Error("This command takes one argument: <namespace>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/namespace_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func (c *NamespaceDeleteCommand) Run(args []string) int {
// Check that we got one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <namespace>")
c.Ui.Error("This command takes one argument: <namespace>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/namespace_inspect.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func (c *NamespaceInspectCommand) Run(args []string) int {
// Check that we got one arguments
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <namespace>")
c.Ui.Error("This command takes one argument: <namespace>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/namespace_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func (c *NamespaceStatusCommand) Run(args []string) int {
// Check that we got one arguments
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <namespace>")
c.Ui.Error("This command takes one argument: <namespace>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/quota_apply.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func (c *QuotaApplyCommand) Run(args []string) int {
// Check that we get exactly one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <input>")
c.Ui.Error("This command takes one argument: <input>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/quota_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (c *QuotaDeleteCommand) Run(args []string) int {
// Check that we got one argument
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <quota>")
c.Ui.Error("This command takes one argument: <quota>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/quota_inspect.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ func (c *QuotaInspectCommand) Run(args []string) int {
// Check that we got one arguments
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <quota>")
c.Ui.Error("This command takes one argument: <quota>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/quota_status.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func (c *QuotaStatusCommand) Run(args []string) int {
// Check that we got one arguments
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <quota>")
c.Ui.Error("This command takes one argument: <quota>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/sentinel_apply.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func (c *SentinelApplyCommand) Run(args []string) int {
// Check that we got exactly two arguments
args = flags.Args()
if l := len(args); l != 2 {
c.Ui.Error("This command takes exactly two arguments, <name> <file>")
c.Ui.Error("This command takes exactly two arguments: <name> <file>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/sentinel_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func (c *SentinelDeleteCommand) Run(args []string) int {
// Check that we got exactly one arguments
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <name>")
c.Ui.Error("This command takes one argument: <name>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/sentinel_read.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func (c *SentinelReadCommand) Run(args []string) int {
// Check that we got exactly one arguments
args = flags.Args()
if l := len(args); l != 1 {
c.Ui.Error("This command takes one argument, <name>")
c.Ui.Error("This command takes one argument: <name>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down
2 changes: 1 addition & 1 deletion command/server_force_leave.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ func (c *ServerForceLeaveCommand) Run(args []string) int {
// Check that we got exactly one node
args = flags.Args()
if len(args) != 1 {
c.Ui.Error("This command takes one argument, <node>")
c.Ui.Error("This command takes one argument: <node>")
c.Ui.Error(commandErrorText(c))
return 1
}
Expand Down

0 comments on commit 0216a8e

Please sign in to comment.