From 3db4c01ea811d72dbd287b49bf5267b531ec8908 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Tue, 16 Jun 2026 18:22:59 +0200 Subject: docs: suggest always writes to stdout, bypasses --quiet Co-Authored-By: Claude Opus 4.8 --- .../superpowers/specs/2026-06-16-suggest-flag-design.md | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'docs/superpowers/specs') diff --git a/docs/superpowers/specs/2026-06-16-suggest-flag-design.md b/docs/superpowers/specs/2026-06-16-suggest-flag-design.md index 5bcd5d6..fb9ad5e 100644 --- a/docs/superpowers/specs/2026-06-16-suggest-flag-design.md +++ b/docs/superpowers/specs/2026-06-16-suggest-flag-design.md @@ -139,10 +139,19 @@ When `lastupdate.epoch` missing: ## Interaction with `--quiet` -`--suggest` output goes to stdout like normal. If combined with `--quiet`, it -follows the existing redirect (writes to log). No special handling — suggest is -a read-only report, quiet just redirects it. Document this is allowed but -unusual. +`--suggest` always writes to the real stdout, even when `--quiet` is also given. +A suggest report in a log file is useless — the user needs to see paste-ready +output on the terminal. + +Implementation: the quiet redirect (currently early in the script, saving the +original stdout to fd 3) must **not** apply to suggest. Either: + +- skip the quiet redirect entirely when `SUGGEST == true`, OR +- have `do_suggest` write to the saved fd 3. + +Skipping the redirect is simpler and preferred: `--suggest` exits before the +backup flow anyway, so quiet has nothing else to suppress. Guard the redirect +block with `if [[ "$QUIET" == true && "$SUGGEST" == false ]]`. ## Scope cuts (YAGNI) -- cgit v1.2.3