Expand description
Interactive prompts with [default: ...] rendering and ?-help.
PromptSource is a trait so terminal, AI/LLM, and scripted-test answer
sources are interchangeable. TerminalPrompt is the line-based impl
used for tests and non-TTY (piped/CI) callers; DialoguerPrompt is the
rich impl that drives dialoguer widgets on a real terminal. The
auto() factory picks between them based on whether stdin is a TTY.
Modules§
- dialoguer
- Rich-TUI
PromptSourceimpl backed bydialoguer.
Structs§
- Field
- Static metadata for one interactive question.
- Terminal
Prompt PromptSourceimpl that renders tostderrand reads fromstdin.
Enums§
- Auto
Prompt PromptSourcereturned byauto: dialoguer-backed when stdin is a TTY, line-based otherwise.
Traits§
- Prompt
Source - Source of answers to interactive prompts.
Functions§
- auto
- TTY stdin gets the rich dialoguer-backed picker; piped / CI stdin
falls back to the line-based
TerminalPromptso scripted input keeps working.