cargo-watch alternatives and similar packages
Based on the "Cargo" category.
Alternatively, view cargo-watch alternatives based on common mentions on social networks and blogs.
Do you think we are missing an alternative of cargo-watch or a related project?
Cargo Watch is a tool to watch your Cargo-based project and run commands when files change. It focuses on the Rust development experience and aims to be flexible enough to suit most without becoming complicated to use.
Looking for a similar tool that you can use for other kinds of projects? Try Watchexec, this project's bigger sibling.
Install or upgrade today with Binstall:
$ cargo binstall cargo-watch
Or with cargo (rustc >= 1.60.0) if you don't have Binstall yet:
$ cargo install cargo-watch
Or unpack directly from the latest pre-built release.
This repository contains a [manual page](./cargo-watch.1) and [shell completions](./completions) that you may want to install; the pre-built packages also include these.
By default, it runs
check. You can easily override this, though:
$ cargo watch [-x command]...
A few examples:
# Run tests only $ cargo watch -x test # Run check then tests $ cargo watch -x check -x test # Run run with arguments $ cargo watch -x 'run -- --some-arg' # Run an arbitrary command $ cargo watch -- echo Hello world # Run with features passed to cargo $ cargo watch --features "foo,bar"
There's a lot more you can do! Check out:
- [Usage guide](./USAGE.md)
- [Manual page](./cargo-watch.1.ronn)
Cargo Watch pairs well with:
- watchexec library: the engine behind this tool.
- clearscreen: to clear the (terminal) screen on every platform.
- command group: to run commands in process groups.
- ignore files: to find, parse, and interpret ignore files.
- project origins: to find the origin(s) directory of a project.
- notify: to respond to file modifications (third-party).
- globset: to match globs (third-party).