Add SQLite library with API, library desktop apps and MobyGames scraper

This commit is contained in:
SirBlob committed 2026-11-02 23:26:31 -05:00
1 parent 6674428346
commit a16444451a
69 files changed
+2988 -1026

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
import os
from jsonfile import PROJECT_ROOT
ENV_FILE = PROJECT_ROOT / ".env"
def env_value(name: str, default: str | None = None) -> str | None:
if os.environ.get(name):
return os.environ[name]
if not ENV_FILE.exists():
return default
for line in ENV_FILE.read_text(encoding="utf-8").splitlines():
key, _, value = line.partition("=")
if key.strip() == name and value.strip():
return value.strip().strip("\"'")
return default