TODO clean this up
(err error, spinner *spinner.Spinner)
| 9 | |
| 10 | // TODO clean this up |
| 11 | func handleError(err error, spinner *spinner.Spinner) { |
| 12 | if err != nil { |
| 13 | if spinner != nil { |
| 14 | // spinner.Suffix = "" |
| 15 | spinner.FinalMSG = err.Error() |
| 16 | spinner.Stop() |
| 17 | } else { |
| 18 | fmt.Println(err) |
| 19 | } |
| 20 | os.Exit(1) |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | // Execute adds all child commands to the root command and sets flags appropriately. |
| 25 | func Execute() { |
no outgoing calls
no test coverage detected