prompter

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CliPrompter

type CliPrompter struct {
	// contains filtered or unexported fields
}

CliPrompter implements ports.Prompter for CLI environments.

func NewCliPrompter

func NewCliPrompter(in io.Reader, out io.Writer) *CliPrompter

NewCliPrompter creates a new CliPrompter.

func (*CliPrompter) FormatNonInteractiveError

func (p *CliPrompter) FormatNonInteractiveError(missing *entities.GrantSet) error

FormatNonInteractiveError creates a helpful error.

func (*CliPrompter) IsInteractive

func (p *CliPrompter) IsInteractive() bool

IsInteractive checks if the input is a terminal.

func (*CliPrompter) PromptForCapabilities

func (p *CliPrompter) PromptForCapabilities(reqs []entities.CapabilityRequest) (*entities.GrantSet, error)

PromptForCapabilities prompts for multiple capabilities.

func (*CliPrompter) PromptForCapability

func (p *CliPrompter) PromptForCapability(req entities.CapabilityRequest) (granted bool, always bool, err error)

PromptForCapability asks the user to grant a single capability.

Jump to

Keyboard shortcuts

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