aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-09-29 12:00:05 +0200
committerDanilo M. <danix@danix.xyz>2026-09-29 12:00:05 +0200
commit261a623de6e214a2f7f143c3ab72a5dd4a117f5c (patch)
tree5b92d225e74394ff3497524d31c92453bb577a82
parent3bcadc0fd35cb1e077a77c847bbc044ca2fabce3 (diff)
downloadunified-desktop-theme-261a623de6e214a2f7f143c3ab72a5dd4a117f5c.tar.gz
unified-desktop-theme-261a623de6e214a2f7f143c3ab72a5dd4a117f5c.zip
feat(install): always hand the output to the steps window
The appearance panel is the usual way a scheme gets applied, so the hints install.sh prints belong on screen whoever calls it, not only when the panel pipes them. install.sh reruns itself as a child, tees the output to the terminal and a temporary log, and passes the log to udt-steps install, keeping the child's exit status. With the window as its main reader, the output is now a summary: only udt-palette's count line rather than all 86 generated paths, and a restart hint in place of the closing ls -l dump. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
-rw-r--r--AGENTS.md10
-rwxr-xr-xinstall.sh23
2 files changed, 25 insertions, 8 deletions
diff --git a/AGENTS.md b/AGENTS.md
index 07ca2b3..eaadbad 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -172,10 +172,12 @@ and pokes quickshell's appearance shell (`ipc call appearance steps`), which
shows one tab per file in a window centred on DP-3. Empty stdin clears the
tab, so each producer reports on every run and a consumer that caught up
disappears by itself. The producers are `udt-grub`, `udt-homepage`,
-`install.sh`'s SDDM block (only the steps still missing), and the appearance
-panel's Theme tab, which pipes all of `install.sh`'s output into an `install`
-tab. A line indented two spaces is a command with a copy button; the rest is
-prose. It replaced notification balloons, which could not be kept open while
+`install.sh`'s SDDM block (only the steps still missing), and `install.sh`
+itself, which reruns itself as a child and hands its whole output to an
+`install` tab on every run, whoever called it: the usual caller is the
+appearance panel, not a terminal. So its output is written for that tab, a
+summary rather than a file list. A line indented two spaces is a command with
+a copy button; the rest is prose. It replaced notification balloons, which could not be kept open while
pasting into a root shell.
## The accent
diff --git a/install.sh b/install.sh
index ff08dba..80d5f13 100755
--- a/install.sh
+++ b/install.sh
@@ -7,6 +7,19 @@ set -euo pipefail
repo="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
target="$HOME/.config/rofi/udt"
+# Everything this prints also becomes the install tab of quickshell's steps
+# window, from whichever caller: the usual one is the appearance panel, not a
+# terminal, so the hints are assumed wanted on screen. The script reruns
+# itself as a child so the output can be both shown live and kept whole.
+if [ -z "${UDT_INSTALL_CHILD:-}" ]; then
+ log="$(mktemp)"
+ trap 'rm -f "$log"' EXIT
+ rc=0
+ UDT_INSTALL_CHILD=1 "$repo/install.sh" "$@" 2>&1 | tee "$log" || rc=$?
+ "$repo/bin/udt-steps" install < "$log"
+ exit "$rc"
+fi
+
mkdir -p "$target" "$HOME/bin" "$HOME/.cache/udt"
# Merge an ini template into a live file key by key: every key the template
@@ -59,7 +72,10 @@ if [ ! -f "$selector" ]; then
install -Dm644 "$repo/palette/roles.conf.default" "$selector"
echo "seeded $selector"
fi
-"$repo/bin/udt-palette"
+# Only the summary line: the list of every generated file, 86 of them, buried
+# the hints in the steps window. sed, not head: head would close the pipe
+# early, and pipefail would read the SIGPIPE as a failed generation.
+"$repo/bin/udt-palette" | sed -n 1p
# Theme files are symlinked individually; accent.rasi is NOT, it points at the
# generated file in the wal cache instead.
@@ -356,7 +372,6 @@ fi
echo
"$repo/bin/udt-grub"
+echo
[ -n "$reloaded" ] && echo "reloaded:$reloaded"
-
-echo "installed:"
-ls -l "$target" "$HOME/bin/udt-accent"
+echo "Qt and GTK apps only reread a theme when they restart; neovim needs :colorscheme udt."