-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(go): Run go get on incomplete builds #2
Conversation
build/golang.go
Outdated
if err != nil { | ||
if opts["install"].(bool) { | ||
log.Logger.Debug("Could not resolve some dependencies. Attempting to run build...") | ||
exec.Command("go", "get", opts["entry-point"].(string)).Output() |
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.
use m.Manifest
over opts["entry-point"]
. The build command parses the opt and sets the module's manifest with it.
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.
Fixed.
build/golang.go
Outdated
if err != nil { | ||
if opts["install"].(bool) { | ||
log.Logger.Debug("Could not resolve some dependencies. Attempting to run build...") | ||
exec.Command("go", "get", opts["entry-point"].(string)).Output() |
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.
exec.Command
returns an error that we could handle. If this command fails, we could exit before calling resolveManifest
again -- up to you.
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.
Fixed.
build/golang.go
Outdated
} | ||
|
||
m.Build.RawDependencies = deps | ||
m.Build.RawDependencies = resolvedDeps |
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.
We could call Dedupe()
on this before returning
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.
Fixed.
ef4f27e
to
012ea89
Compare
012ea89
to
b476866
Compare
Resolves #1.