1. Is Waddle listening?
sh
curl localhost:4404/healthjson
{ "ok": true, "duck": "quack", "moods": ["quack", "dance", "pet", "sleep"] }A running Waddle also says whether it's in the coop (house) and about the screen it's on (screen).
2. Make it say something
curl localhost:4404/quack -H 'content-type: application/json' -d '{"text":"first quack!"}'waddle say first quack!json
{ "ok": true, "mood": "quack", "text": "first quack!" }The mood is quack unless you pick another: dance, pet or sleep. More in Make Waddle react.
3. Put it in a script
A git hook that tells you each commit went in. Save it as .git/hooks/post-commit and make it executable (chmod +x):
sh
#!/bin/sh
# Tell Waddle; never hold up the commit if Waddle isn't running.
waddle say "committed!" >/dev/null 2>&1 || true4. Let it watch a long command
sh
waddle wait npm testYour tests run as usual in your terminal. When they finish, Waddle walks over: happy if they passed, with the last line they printed if not. Click Waddle to jump back to that terminal. waddle wait exits with the command's own exit code, so it fits in scripts.
Want that for every long command, without typing waddle wait? See Tell me when tests finish.