-
Notifications
You must be signed in to change notification settings - Fork 259
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Improve spin watch
#1341
Improve spin watch
#1341
Conversation
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'm wondering if I just haven't quite clicked into the mental model of the watch settings because it's not yet quite clear to me how these options fit together. I'm wondering what the impact would be of expressing it in terms of "what changes do I want to cause a restart" (assets, Wasm, source code) - would it be clearer or more confusing? (Like the "skip-build" setting is I think saying I don't want source code changes to cause a restart. Except that "watch-wasm" seems to be saying that too.)
(But I am also a bit vague on skip-up
so I guess it's not just that.)
d7aa026
to
55aab1b
Compare
55aab1b
to
7d8bb23
Compare
@itowlson I pushed some fixes for all the comment threads we had going and I'm ready for re-review. |
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.
Thanks! A few nits/suggestions but nothing that needs to block getting this into 1.1 - happy to revisit in future polishing/refactoring passes. Looks good!
src/commands/watch.rs
Outdated
@@ -119,7 +111,10 @@ impl WatchCommand { | |||
return Ok::<(), Infallible>(()); | |||
} | |||
|
|||
// TODO: Check if spin.toml changed and reconfigure | |||
if event.paths().any(|(p, _)| p.ends_with("spin.toml")) { |
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.
You should know the path of the manifest; use that instead of the literal text "spin.toml"
7d8bb23
to
ceaeaa8
Compare
Signed-off-by: Caleb Schoepp <caleb.schoepp@fermyon.com>
ceaeaa8
to
f74ff4e
Compare
Changes made
spin watch
command--skip-build
flag to support the non-default use case i.e. you want to run build yourselfExample use cases
spin watch
component.build.watch
and yourcomponent.files
spin watch --skip-build
component.source
and yourcomponent.files