Initial commit: R0Installer source, patch generator, API backend and build scripts

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-06-27 18:03:44 +08:00
commit 6124d6060c
33 changed files with 8389 additions and 0 deletions
+21
View File
@@ -0,0 +1,21 @@
<?php
require_once __DIR__ . '/config.php';
require_once __DIR__ . '/Medoo.php';
use Medoo\Medoo;
function getDb() {
static $db = null;
if ($db === null) {
$db = new Medoo([
'type' => DB_TYPE,
'host' => DB_HOST,
'port' => DB_PORT,
'database' => DB_NAME,
'username' => DB_USER,
'password' => DB_PASS,
'charset' => DB_CHARSET,
]);
}
return $db;
}