-
Notifications
You must be signed in to change notification settings - Fork 288
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
logs: wire deps [ch8434] #3635
logs: wire deps [ch8434] #3635
Conversation
internal/hud/server/logs_reader.go
Outdated
@@ -94,17 +90,22 @@ func (ls *LogStreamer) Handle(v proto_webview.View) error { | |||
|
|||
return nil | |||
} | |||
func StreamLogs(ctx context.Context, host model.WebHost, port model.WebPort, printer *hud.IncrementalPrinter) error { |
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.
model.WebURL might be a better choice here. it will behave correctly if the user specifies 0.0.0.0 (there's a subtle difference between the host we're listening on and the host we're connecting to)
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.
ugh it SHOULD be model.WebURL except that encodes the schema too :( i might play with it and split it out into model.BaseWebURL
and model.WebURL
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.
oh wait duh I can just manipulate the url.URL
to change the schema.
internal/cli/logs.go
Outdated
return err | ||
} | ||
|
||
return server.StreamLogs(ctx, logDeps.host, logDeps.port, logDeps.printer) |
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.
add the addConnectServerFlags() call to this file while you're here?
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.
I've got that in a different ticket!
Hello @nicks, @jazzdan,
Please review the following commits I made in branch maiamcc/logs-wire-deps:
ac4c504 (2020-07-29 15:10:08 -0400)
logs: wire deps [ch8434]
Code review reminders, by giving a LGTM you attest that: