Skip to content

Add --quiet / -q flag (suppress all non-error output) #108

Description

@Manavarya09

Add a top-level --quiet / -q flag to the extract command so CI pipelines can run designlang without flooding their build logs.

What

When --quiet is passed:

  • The progress spinner (ora) is suppressed.
  • All informational console.log lines are skipped.
  • Only the final summary block (or errors written to stderr) prints.
  • The exit code is unchanged (0 on success, 1 on error).

Where

bin/design-extract.js. Add the option to the main extract command (and ideally to the other subcommands too: brand, pair, brands).

A clean way: thread an opts.quiet boolean through the action handler and gate spinner.start() plus the console.log calls behind it. spinner = ora({ ... isSilent: opts.quiet }) is the cleanest path.

Acceptance

  • npx designlang stripe.com --quiet prints nothing on success.
  • npx designlang stripe.com -q does the same.
  • Errors still go to stderr and the exit code still reflects success/failure.
  • An invalid URL still prints the error in quiet mode (via console.error).

Scope

~20 lines across the extract / brand / pair commands. Useful for the CI drift bot use case.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestgood first issueGood for newcomersjavascriptPull requests that update javascript code

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions