WARNING!! I’ve successfully used this script on my system but it may or may not completely obliterate your computer/website. Please make a backup before using this script!!
You’re welcome to use and modify the script as you see fit. Please let me know if you find it useful and/or if you have any improvements/suggestions. I’ve taken out a few things that are custom to what I do with Piecrust, such as rsyncing _counter to a development server for testing, and a few items from the template that are specific to my site. I haven’t tested what I posted after the edits, just FYI. If you find something broken, please let me know.