Skip to content

Commit

Permalink
Merge 4f416bf into 0972347
Browse files Browse the repository at this point in the history
  • Loading branch information
bitcodr committed Jul 31, 2020
2 parents 0972347 + 4f416bf commit 92d2fed
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/fscrypt/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,10 @@ func getErrorSuggestions(err error) string {
// returned error prepends an error tag and the name of the relevant command,
// and it will make fscrypt return a non-zero exit value.
func newExitError(c *cli.Context, err error) error {
if err == nil {
return nil
}

// Prepend the error tag and full name, and append suggestions (if any)
prefix := "[ERROR] " + getFullName(c) + ": "
message := prefix + wrapText(err.Error(), utf8.RuneCountInString(prefix))
Expand Down

0 comments on commit 92d2fed

Please sign in to comment.