runtime

package
v2.17.3 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2026 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// AppContextKey is the context key under which the CLI's AppContext is stored;
	// set it with context.WithValue and read it back with From.
	AppContextKey contextKey = "arcane_app_context"

	OutputModeText OutputMode = "text"
	OutputModeJSON OutputMode = "json"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AppContext

type AppContext struct {
	Options
	FleetConfirmed bool
	// contains filtered or unexported fields
}

func From

func From(ctx context.Context) (*AppContext, bool)

func New

func New(opts Options) (*AppContext, error)

func (*AppContext) Client

func (a *AppContext) Client() (*client.Client, error)

func (*AppContext) Config

func (a *AppContext) Config() *types.Config

func (*AppContext) EnvID

func (a *AppContext) EnvID() string

func (*AppContext) Environments added in v2.16.0

func (a *AppContext) Environments(ctx context.Context) ([]environment.Environment, error)

Environments loads the complete visible, enabled environment list once per invocation.

func (*AppContext) IsJSON

func (a *AppContext) IsJSON() bool

func (*AppContext) PreviewEnabled added in v2.16.0

func (a *AppContext) PreviewEnabled() bool

PreviewEnabled reports whether this command still needs an environment scope.

func (*AppContext) SelectEnvironment added in v2.16.0

func (a *AppContext) SelectEnvironment(id string)

SelectEnvironment pins subsequent requests without changing persisted configuration.

func (*AppContext) UnauthClient

func (a *AppContext) UnauthClient() (*client.Client, error)

type Options

type Options struct {
	EnvOverride    string
	OutputMode     OutputMode
	AssumeYes      bool
	NoColor        bool
	RequestTimeout time.Duration
}

type OutputMode

type OutputMode string

Jump to

Keyboard shortcuts

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