From e47ce379ad16ea9a699dd434a3ad486fcdd9cf9f Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Mon, 27 Jul 2026 15:24:35 -0700 Subject: [PATCH] Drop gum from the orchestrator's progress lines The dashboard owns the visible UI: it captures the orchestrator's stdout into the support log and strips CSI sequences on the way in, so the colouring was never seen by anyone. gum charged a Go process start per line for it, on every phase and every package group. Plain writes keep the same indented shape. Flushing stays: pacstrap and arch-chroot inherit this fd, so buffering would reorder our lines against theirs in the log. Co-Authored-By: Claude Opus 5 (1M context) --- .../usr/share/omarchy-iso/orchestrator/ui.py | 30 +++++++++++-------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/configs/airootfs/usr/share/omarchy-iso/orchestrator/ui.py b/configs/airootfs/usr/share/omarchy-iso/orchestrator/ui.py index 786c141..23e3a5a 100644 --- a/configs/airootfs/usr/share/omarchy-iso/orchestrator/ui.py +++ b/configs/airootfs/usr/share/omarchy-iso/orchestrator/ui.py @@ -1,24 +1,28 @@ -"""Thin gum wrapper so the orchestrator keeps the same terminal UX as the -existing bash installer.""" +"""Orchestrator progress lines. + +These land in the install log, not on a screen: omarchy-install-dashboard owns +the visible UI, captures the orchestrator's stdout into the support log, and +strips CSI sequences on the way in. The colouring was therefore never seen by +anyone, while gum charged a Go process start per line for it. Plain writes keep +the same indented shape at no cost. + +Flush every line: pacstrap and arch-chroot inherit this fd, so buffering here +would reorder our lines against theirs in the log. +""" from __future__ import annotations -import subprocess +import sys -def style(text: str, *, foreground: str | None = None, padding: str | None = None) -> None: - cmd = ["gum", "style"] - if foreground: - cmd += ["--foreground", foreground] - if padding: - cmd += ["--padding", padding] - cmd.append(text) - subprocess.run(cmd, check=False) +def _emit(text: str) -> None: + sys.stdout.write(f"\n {text}\n") + sys.stdout.flush() def info(text: str) -> None: - style(text, foreground="3", padding="1 0 0 4") + _emit(text) def error(text: str) -> None: - style(text, foreground="1", padding="1 0 0 4") + _emit(text)