cli & console output #4

Merged
bbaudouin merged 9 commits from ux into develop 2026-07-22 07:57:32 +01:00
Showing only changes of commit 3746f32cd0 - Show all commits
+6
View File
@@ -1,3 +1,5 @@
import logging
import os
import sys
from .level import Level
@@ -43,6 +45,10 @@ def play_donjon(level: Level) -> None:
def app() -> None:
os.makedirs('logs', exist_ok=True)
logging.basicConfig(filename='logs/app.log', level=logging.getLevelName(os.environ.get('ELIRON_LOGS', 'ERROR')))
logging.info('start')
loaded_character = load_character(sys.argv[1] if len(sys.argv) > 1 else "Jamin")
if not loaded_character:
sys.exit(-1)