Skip to main content

should_print

Function should_print 

pub fn should_print(quiet: bool, no_banner: bool) -> bool
Expand description

Decision policy for whether to print the banner AT ALL. Three switches, most-restrictive wins:

  1. quiet=true → always off (matches the existing log suppression).
  2. no_banner=true → always off (targeted opt-out).
  3. Otherwise → on iff stderr is a TTY (so file redirects stay clean).

Note: even when should_print returns false, callers MUST still print the banner when the pre-flight status is non-Ready — failure feedback is too important to swallow on a piped invocation.