drizzle-output-modes

Select and interpret drizzle-kit text versus JSON output modes in non-TTY contexts.

Updated Jul 24, 2026
One-click install
npx skills add https://github.com/saad-tayyab/lumora --skill drizzle-output-modes-saad-tayyab
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: drizzle-output-modes
Source: https://github.com/saad-tayyab/lumora/tree/main/.agents/skills/drizzle-output-modes
Command: npx skills add https://github.com/saad-tayyab/lumora --skill drizzle-output-modes-saad-tayyab

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Running drizzle-kit generate, push, or check in CI pipelines and other non-TTY environments raises questions about which --output mode to use, whether the CLI will prompt interactively, and how to read the missing-decisions report when it exits with code 2. ## Core Features & Use Cases - Output Mode Selection: Explains the difference between --output text (human-readable, potentially interactive) and --output json (machine-readable envelope, always non-interactive). - Interactivity Reasoning: Defines the exact rule (interactive = text output plus TTY stdin) so scripts never hang waiting for prompts. - Missing-Decisions Report Parsing: Decodes the 'missing_hints: N unresolved decisions' text report, including rename_or_create and confirm_data_loss items with their --hints snippets. - Use Case: A CI job running drizzle-kit generate fails with exit code 2; use this Skill to read the text report, build the correct --hints JSON array, and re-run non-interactively. ## Quick Start Ask the AI to explain why drizzle-kit generate exited with code 2 in CI and how to resolve the missing_hints report with the right --output mode.

Frequently Asked Questions about drizzle-output-modes

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I choose between drizzle-kit --output text and --output json?

Use --output text for human-readable progress and results on stdout, and --output json when you need a single machine-readable JSON envelope for every status including errors. The json mode is always non-interactive, making it the right choice for automation.

Why does drizzle-kit hang or prompt in CI pipelines?

Drizzle-kit is interactive only when rendering text output and stdin is a TTY. In CI, stdin is not a TTY, so under --output text it will not prompt; instead it prints a missing-decisions report and exits with code 2 when decisions are unresolved.

What does the drizzle-kit missing_hints report with exit code 2 mean?

It means the CLI was non-interactive and could not resolve one or more decisions from your --hints or --hints-file. The report lists rename_or_create decisions first, then confirm_data_loss decisions, each with an 'Add to --hints' snippet to supply on re-run.

Is drizzle-kit --output json ever interactive?

No. The --output json mode is always non-interactive regardless of whether stdin is a TTY. When decisions are unresolved it returns a missing_hints JSON envelope instead of prompting.

How does drizzle-kit check behave with --output json?

check --output json is a no-hint, non-interactive gate that emits an ok envelope when the migrations folder is valid and a check_error envelope for snapshot-integrity problems or unreported branch conflicts. It never reaches the missing-decisions path.