新增了客户端打包成sdk的功能和服务端docker镜像打包的功能,并修复了一些问题

This commit is contained in:
2026-07-07 09:48:01 +00:00
parent cd3dca042d
commit 9e545cb328
50 changed files with 5251 additions and 875 deletions
+11 -3
View File
@@ -5,8 +5,16 @@ from dotenv import load_dotenv
load_dotenv()
DB_FILE = os.getenv("DB_FILE")
SQL_FILE = os.getenv("SQL_FILE")
BASE_DIR = Path(__file__).resolve().parent
def configured_path(name: str, default: str) -> Path:
path = Path(os.getenv(name, default)).expanduser()
return path if path.is_absolute() else BASE_DIR / path
DB_FILE = configured_path("DB_FILE", "mini.db")
SQL_FILE = configured_path("SQL_FILE", "tables.sql")
# 初始化数据库
def init_db():
@@ -27,4 +35,4 @@ def get_conn():
return conn
if __name__ == "__main__":
init_db()
init_db()