Add Gaja to the list of computers

This commit is contained in:
2026-06-08 22:46:46 +02:00
parent c337a0d5f1
commit b15f87e3d5
2 changed files with 34 additions and 2 deletions

View File

@ -51,13 +51,26 @@ def parse_output(text: str) -> list[dict]:
# User checks
if "Gabi is not online" in line:
actions.append({"icon": "👤", "title": "Gabi's PC", "detail": "Not logged in — no action needed"})
actions.append({"icon": "💻", "title": "Gabi's PC", "detail": "Not logged in — no action needed"})
continue
if "terminate-user gabi" in line or "terminated" in line.lower():
m = re.match(r"terminate-user gabi\b", line)
if m or "session terminated" in line.lower():
actions.append({"icon": "💻", "title": "Gabi's PC", "detail": "Session terminated"})
continue
if "Gaja is not online" in line:
actions.append({"icon": "💻", "title": "Gaja's PC", "detail": "Not logged in — no action needed"})
continue
if "Gaja's PC is unreachable" in line:
actions.append({"icon": "", "title": "Gaja's PC", "detail": "Unreachable (ping failed)"})
continue
if "Gaja's PC: logged out" in line:
actions.append({"icon": "💻", "title": "Gaja's PC", "detail": "Logged out"})
continue
# If no structured items found, fallback to raw
if not actions:
actions.append({"icon": "📜", "title": "Output", "detail": text.strip() or "(empty)"})