Just a thought as I've done this on a couple of the bots I run to ease upgrades a bit.
For example, I've added the following to main.php before the code that loads the official modules. If I modify an official module, I move it to one of the custom directories. Any modules I write or grab from this site also go into the custom directories.
// Load up all custom core-modules
$folder = dir("./custom-core/");
while ($mod = $folder->read())
{
if (!is_dir($mod) && !preg_match("/^_/", $mod) && preg_match("/php$/i", $mod))
{
require_once "custom-core/" . $mod;
$bot -> log("CCORE", "LOAD", $mod);
}
}
// Load up all custom modules
$folder = dir("./custom-modules/");
while ($mod = $folder->read())
{
if (!is_dir($mod) && !preg_match("/^_/", $mod) && preg_match("/php$/i", $mod) && (($guildbot && !preg_match("/_RAID/", $mod)) || (!$guildbot && !preg_match("/_GUILD/", $mod))))
{
require_once "custom-modules/" . $mod;
$bot -> log("CMOD", "LOAD", $mod);
}
}