-
Notifications
You must be signed in to change notification settings - Fork 81
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
Support for workspaces #52
Comments
Can you explain what we'd need to watch for / execute in this context? At least for quick reference. |
I think there are two strategies:
|
Could probably do both, too. I'm not going to pick this up for the moment, but would merge a PR that implements it. |
I think there are two aspects to workspace support: What @malbarbo suggested are these two modes:
Strategy (1) would be a good default since workspaces can be big. On the other hand it is possible that changes have side effects on other crates within the same workspace. So it's definitely interesting to have a way to pass .. howeverI suggest to adopt this alternative strategy: cargo watch could always watch the entire workspace. If the user passes a package flag ( The difference is this: |
With version 4.0.0, you can now run arbitrary commands and watch a lot more stuff by default. While that's not first-class support for workspaces yet, it's a step towards that. In addition, the |
I'd like to take a crack at implementing this if no one else is already working on it. @passcod got any suggestions for where to start? |
Absolutely, thanks for offering! I actually don't have any idea of what this would do! So I guess first step would be figuring out what the action would be. There's a bunch of stuff in the comments but I haven't really thought about this in, uh, two years. I don't think this needs watchexec support, which simplifies things. There will need to be a flag added to the clap arguments, then whatever logic happens to translate/affect the arguments for watchexec. And that should be all! |
Personally, I find that the current version works well with a workspace project, where you can choose what package/action to run with the I would however love to see support for |
|
I'd prefer that filed as a different issue (possible bug, not part of whatever feature this issue materialises as) |
I've created #175 |
Consider adding support to use cargo watch in a workspace project.
You can see with
cargo +nightly build --help
the kind of options for workspace projects.The text was updated successfully, but these errors were encountered: