prompt

package
v0.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 13, 2026 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsInteractive

func IsInteractive() bool

IsInteractive returns true when stdin is a terminal. Commands should skip confirmation prompts when this is false, enabling scripted and agentic usage without --force.

func Select

func Select(promptLabel string, items []string) (int, error)

Select presents a fuzzy-finder list and returns the chosen index. items are the display strings shown to the user.

func String

func String(label, defaultVal string) string

String prompts the user for text input. If defaultVal is non-empty, it is shown in brackets and returned when the user presses Enter without typing.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL