Skip to content

Commit 97d69cc

Browse files
farisjnywilken
authored andcommitted
Add Descriptive Error Message to Upgrade Command (#752)
* Add Descriptive Error Message to Upgrade Command * Reword Error Message
1 parent ed6dc02 commit 97d69cc

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

cmd/upgrade.go

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,18 @@ You can always delete this file.
2323
`,
2424
RunE: func(cmd *cobra.Command, args []string) error {
2525
c := cli.New(Version)
26-
return updateCLI(c)
26+
err := updateCLI(c)
27+
if err != nil {
28+
return fmt.Errorf(`
29+
30+
We were not able to upgrade the cli because we encountered an error:
31+
%s
32+
33+
Please check the FAQ for solutions to common upgrading issues.
34+
35+
https://exercism.io/faqs`, err)
36+
}
37+
return nil
2738
},
2839
}
2940

0 commit comments

Comments
 (0)