#build #container #command #trigger #run #succeed #another

bin+lib watchdock

Trigger a build inside a build container (e.g. using cargo-watch), then optionally run another command outside the container when the inner build command succeeds.

1 unstable release

0.1.0 Sep 23, 2024

#1 in #succeed

Download history 103/week @ 2024-09-17 75/week @ 2024-09-24 16/week @ 2024-10-01

194 downloads per month

MIT license

12KB
216 lines

watchdock

Trigger a build inside a build container (e.g. using cargo-watch), then optionally run another command outside the container when the inner build command succeeds.

Inside your build container (with --volume ./target/watchdock:/run/watchdock):

cd /src
watchdock listen /run/watchdock/sock cargo build

Then outside your container:

cargo watch -s "watchdock trigger-run ./target/watchdock/sock echo 'DONE - now do my useful thing'"

Dependencies

~9–20MB
~253K SLoC