-
-
Notifications
You must be signed in to change notification settings - Fork 578
show go.mod in buffalo info sort of fixes #1159 #1194
Conversation
Codecov Report
@@ Coverage Diff @@
## development #1194 +/- ##
===============================================
- Coverage 53.72% 53.47% -0.26%
===============================================
Files 75 75
Lines 3842 3860 +18
===============================================
Hits 2064 2064
- Misses 1655 1673 +18
Partials 123 123
Continue to review full report at Codecov.
|
if err := runInfoCmds(); err != nil { | ||
return errors.WithStack(err) | ||
} | ||
return infoGoMod() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything looks good, but I have just a question, why we don't do something like:
return errors.WithStack(infoGoMod())
, if the error is nil it will return nil anyway.
Good question. Here’s why I didn’t, because I know we’ll end up adding more later and didn’t want to have to rewrite it then. lol
…--
Mark Bates
On Jul 27, 2018, 2:24 PM +0100, kteb ***@***.***>, wrote:
@kteb commented on this pull request.
In buffalo/cmd/info.go:
> @@ -32,7 +33,10 @@ var infoCmd = &cobra.Command{
bb.WriteString(fmt.Sprintf("%s=%v\n", f.Name, rv.FieldByName(f.Name).Interface()))
}
- return runInfoCmds()
+ if err := runInfoCmds(); err != nil {
+ return errors.WithStack(err)
+ }
+ return infoGoMod()
Everything looks good, but I have just a question, why we don't do something like:
return errors.WithStack(infoGoMod()), if the error is nil it will return nil anyway.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok then everything is fine for me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With selecting Approve it's better.
No description provided.