Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AskYesNo ¶ added in v0.2.54
func AskYesNo() bool
AskYesNo prints nothing itself — the caller is expected to have already prompted the user. It reads one line from stdin and returns true unless the user explicitly types "n" or "no" (case-insensitive). An empty input (just pressing Enter) is treated as yes. Any read error (including Ctrl+C / SIGINT cancellation) is treated as no.
func IsStdinTerminal ¶ added in v0.2.54
func IsStdinTerminal() bool
IsStdinTerminal reports whether stdin is connected to an interactive terminal. Returns false when stdin is a pipe, a file redirect, or otherwise non-interactive.
func ReadString ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.