proxy.golang.org : github.com/radiusmethod/promptui : v0.10.2
Package promptui is a library providing a simple interface to create command-line prompts for go. It can be easily integrated into spf13/cobra, urfave/cli or any cli go application. promptui has two main input modes: Prompt provides a single line for user input. It supports optional live validation, confirmation and masking the input. Select provides a list of options to choose from. It supports pagination, search, detailed view and custom templates. This is an example for the Prompt mode of promptui. In this example, a prompt is created with a validator function that validates the given value to make sure its a number. If successful, it will output the chosen number in a formatted message. This is an example for the Select mode of promptui. In this example, a select is created with the days of the week as its items. When an item is selected, the selected day will be displayed in a formatted message.
Registry -
Documentation -
Download -
JSON
purl: pkg:golang/github.com/radiusmethod/[email protected]
Published:
Indexed:
- github.com/chzyer/readline v1.5.1
- github.com/chzyer/test v1.0.0
- golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5