AlphaKretin/bastion-bot

Rework self-update system

AlphaKretin opened this issue · 0 comments

The current system I have in place to keep commands updated has a number of issues. For one, the fact it downloads on start-up interferes with the testing of changes to commands that I haven't committed yet. Also, that it only downloads on start-up is inconvenient, I haven't yet got around to making a command and/or timer for it. It also doesn't update the whole bot, only commands, and I'm editing the other parts more than I expected when designing the command system. Finally, command hot-loading is generally not the wisest idea.

An alternative would be to find a way to run an automated build script through a command, that pulls changes from GitHub, updates databases, and then restarts the process to load the changed files. I'm not 100% sure this is possible, however. It would also require assuming anyone hosting their own Bastion copies used pm2 as I do.