City CI must run Claude Code without hanging on interactive prompts. Which flag pattern fits?
Select an answer to reveal the explanation.
Short Explanation
CI bots don't sit at a keyboard waiting for "press Enter." The -p print/non-interactive flag keeps the city pipeline moving without hanging on prompts.
Full Explanation
City CI must run Claude Code without hanging on interactive prompts. The fitting pattern is the print/non-interactive -p flag so the job never waits on prompts. Unattended municipal pipelines need a non-interactive entry point by design.
The -p flag works because CI runners are not humans at a keyboard. Non-interactive print mode executes the requested Claude Code invocation, emits output suitable for logs and gates, and returns control to the pipeline without blocking on TTY confirmation. That keeps city builds, lint-fix jobs, or automated review assists moving on schedule.
Launching an interactive TTY session and hoping the runner sends keystrokes fails because most CI environments lack reliable interactive input and will hang. Omitting automation flags and requiring a human at the console for every pipeline fails by destroying unattended CI. Disabling networking and expecting Claude Code to block until manually attached fails by concept: network restrictions and manual attach are not substitutes for non-interactive mode and typically make hangs worse.
Exam caveat: -p/non-interactive is the CI automation flag pattern; do not confuse it with simply "running Claude somehow" under an interactive assumption. Operational check: run the city CI job with -p, confirm it completes without waiting on prompts, and verify logs capture the printed result for the pipeline gate.