Skip to content

Commit

Permalink
Merge pull request #181 from suhussai/bootstrap_error_fix
Browse files Browse the repository at this point in the history
check if err is nil before printing it
  • Loading branch information
lkysow committed Nov 6, 2017
2 parents 4670b67 + 9921486 commit 2c45288
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmd/bootstrap.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ func (b *BootstrapCmd) Init() *cobra.Command {
Short: "Start a guided tour of Atlantis",
RunE: func(cmd *cobra.Command, args []string) error {
err := bootstrap.Start()
fmt.Fprintf(os.Stderr, "\033[31mError: %s\033[39m\n\n", err.Error())
if err != nil {
fmt.Fprintf(os.Stderr, "\033[31mError: %s\033[39m\n\n", err.Error())
}
return err
},
}
Expand Down

0 comments on commit 2c45288

Please sign in to comment.