capabilities

package
v0.4.5-alpha Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TerminalPrompter

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

TerminalPrompter provides interactive terminal prompting for capability grants.

func NewTerminalPrompter

func NewTerminalPrompter() *TerminalPrompter

NewTerminalPrompter creates a new TerminalPrompter.

func (*TerminalPrompter) FormatNonInteractiveError

func (p *TerminalPrompter) FormatNonInteractiveError(missing *sdkEntities.GrantSet) error

FormatNonInteractiveError creates a helpful error message for non-interactive mode.

func (*TerminalPrompter) IsInteractive

func (p *TerminalPrompter) IsInteractive() bool

IsInteractive checks if we're running in an interactive terminal.

func (*TerminalPrompter) PromptForCapabilities

func (p *TerminalPrompter) PromptForCapabilities(reqs []sdkEntities.CapabilityRequest) (*sdkEntities.GrantSet, error)

PromptForCapabilities prompts for multiple capabilities at once.

func (*TerminalPrompter) PromptForCapability

func (p *TerminalPrompter) PromptForCapability(req sdkEntities.CapabilityRequest) (granted bool, always bool, err error)

PromptForCapability asks the user to grant a capability.

func (*TerminalPrompter) PromptForCapabilityString

func (p *TerminalPrompter) PromptForCapabilityString(desc string, isBroad bool) (granted bool, always bool, err error)

PromptForCapabilityString asks the user whether to grant a capability described by a string.

func (*TerminalPrompter) PromptForProfileTrustWithGrantSet

func (p *TerminalPrompter) PromptForProfileTrustWithGrantSet(
	url string,
	requiredCaps map[string]*sdkEntities.GrantSet,
) (bool, error)

PromptForProfileTrustWithGrantSet prompts the user to trust a remote profile source. Displays the profile URL and required capabilities for informed decision.

Jump to

Keyboard shortcuts

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