aboutsummaryrefslogtreecommitdiff
path: root/cmd/errors.go
diff options
context:
space:
mode:
authorJoe Richey joerichey@google.com <joerichey@google.com>2017-10-17 02:39:07 -0700
committerJoseph Richey <joerichey94@gmail.com>2017-10-19 02:22:26 -0700
commitbab7dfdf68075b345e4de3ae79ea685ca884668f (patch)
treeeced4ecdfd37aae1a92f28ba0864837db1205eb0 /cmd/errors.go
parentb5cc60b2b974645f0d09721c292cd243d049cbcf (diff)
Move around and fscrypt refactor
Diffstat (limited to 'cmd/errors.go')
-rw-r--r--cmd/errors.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmd/errors.go b/cmd/errors.go
index 0252fed..d4aca6d 100644
--- a/cmd/errors.go
+++ b/cmd/errors.go
@@ -49,11 +49,11 @@ type UsageError string
func (u UsageError) Error() string { return string(u) }
-// CheckExpectedArgs returns a UsageError if the number of arguements in the
+// CheckExpectedArgs returns a UsageError if the number of arguments in the
// context does not match expectedArgs. If atMost is set, the number of args
// is allowed to be less than expectedArgs.
func CheckExpectedArgs(ctx *Context, expectedArgs int, atMost bool) error {
- // Check the number of arguements and build the message.
+ // Check the number of arguments and build the message.
nArgs := len(ctx.Args)
message := "expected"
if atMost {
@@ -107,9 +107,9 @@ func (ctx *Context) processError(err error) {
}
// Errors with a help text should print it out.
- if helpText := ctx.getHelp(err); helpText != "" {
+ if helpText := ctx.getHelpText(err); helpText != "" {
fmt.Fprintln(os.Stderr)
- fmt.Fprintln(os.Stderr, wrapText(helpText, 0))
+ fmt.Fprintln(os.Stderr, WrapText(helpText, 0))
}
os.Exit(FailureCode)
return