Here is a hg hook to prevent you from pushing changes when the Firefox tinderbox is reporting anything other than success.
create a new file, and paste this into it:
#!/bin/bash
if ! curl -s http://tinderbox.mozilla.org/showbuilds.cgi?tree=Firefox\&quickparse=1 | cut -d '|' -f 4 | grep -v "success"; then
echo "tinderbox is open. pushing...."
exit 0
fi
echo "tinderbox is burning. exiting"
exit 1
Then in your .hgrc file, add a line like:
preoutgoing.hg_tbox_hook = /Users/dougt/builds/hg_tbox_hook
Result my vary. Don’t depend on this to save your butt; check tinderbox often. Note that there is some delay between the time that tinderbox knows that there is a problem, and the time that the “quickparse.txt” file is generated. Hopefully, we can resolve this quickly so that this hook is more useful.
thanks philor for the pro tip. script above now uses the non-static tinderbox quicktest url.
3 Comments
Only problem is that that means I’d never be able to check in
Thanks for the cool tip!
Nice one. And my recommendation for an override flag would be “–make-beltzner-scream”