Documentation
¶
Index ¶
- func ChooseOptDepends(ctx context.Context, options []string, verb string, interactive bool) ([]string, error)
- func FlattenPkgs(ctx context.Context, found map[string][]db.Package, verb string, ...) []db.Package
- func PkgPrompt(ctx context.Context, options []db.Package, verb string, interactive bool) (db.Package, error)
- func PromptViewScript(ctx context.Context, script, name, style string, interactive bool) error
- func ShowScript(path, name, style string) error
- func YesNoPrompt(ctx context.Context, msg string, interactive, def bool) (bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ChooseOptDepends ¶
func ChooseOptDepends(ctx context.Context, options []string, verb string, interactive bool) ([]string, error)
ChooseOptDepends asks the user to choose between multiple optional dependencies. The user may choose multiple items.
func FlattenPkgs ¶
func FlattenPkgs(ctx context.Context, found map[string][]db.Package, verb string, interactive bool) []db.Package
FlattenPkgs attempts to flatten the a map of slices of packages into a single slice of packages by prompting the user if multiple packages match.
func PkgPrompt ¶
func PkgPrompt(ctx context.Context, options []db.Package, verb string, interactive bool) (db.Package, error)
PkgPrompt asks the user to choose between multiple packages.
func PromptViewScript ¶
PromptViewScript asks the user if they'd like to see a script, shows it if they answer yes, then asks if they'd still like to continue, and exits if they answer no.
func ShowScript ¶
ShowScript uses the built-in pager to display a script at a given path, in the given syntax highlighting style.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.