I'm using cargo watch with other scripts.
For example, I need to run tailwindcss to execute when my rs files change because I use tailwindcss templating in rust.
But the problem is that when tailwindcss outputs the resulted css, the cargo detects this change and rerun again.
The best solution is to make it ignore watch events during execution. I use make to execute a lot of scripts together.
the command I use:
cargo watch -- make run
Makefile:
run:
bun dev
cargo run
The --delay option unfortunately doesn't ignore changes files are being changed during the duration. I tried to increase it to 5 seconds but it only delays the actual execution, it will execute multiple times, since multiple commands are changing files.
I'm using cargo watch with other scripts. For example, I need to run tailwindcss to execute when my rs files change because I use tailwindcss templating in rust. But the problem is that when tailwindcss outputs the resulted css, the cargo detects this change and rerun again. The best solution is to make it ignore watch events during execution. I use make to execute a lot of scripts together.
the command I use:
Makefile:
The
--delay
option unfortunately doesn't ignore changes files are being changed during the duration. I tried to increase it to 5 seconds but it only delays the actual execution, it will execute multiple times, since multiple commands are changing files.Is there a feature that lets me do this?