update.sh - is the main "startup" script. It simply tells the bot to run a backup, check for updates via git, and then start
backup.sh - does what it says on the tin. It backs up all .db and .cfg files (the only important files, the rest can be re-obtained via git). I also have this line in crontab for it: @daily /home/backup.sh >/home/logs/hmhbackup.log 2>/home/logs/hmhbackuperror.log so backup.sh runs whenever the bot gets updated, as well as once a day. I have not yet set a limit on how many backups to retain.
willie.sh - This is a heavily modified script that I've had for a few years, and it's sort of "evolved" as requirements appeared. I never really added "graceful" stopping. As of now it makes sure python has permission to read and write to the db (perms overkill, I was lazy) and then starts 2 copies of willie, first making sure their previous copies are no longer running.
startwillie.sh startwilliequake.sh