hooks

package
v0.1.0-preview.6.rc Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const EnvFile = ".env"

EnvFile is the name of the environment file

Variables

This section is empty.

Functions

func ApplyMiddleware

func ApplyMiddleware(commands []*cli.Command, chain *ActionChain)

func LoadEnvFile

func LoadEnvFile(ctx *cli.Context) error

func WithCommandMetricsContext

func WithCommandMetricsContext(ctx *cli.Context) error

func WithFirstRunTelemetryPrompt

func WithFirstRunTelemetryPrompt(cCtx *cli.Context) error

WithFirstRunTelemetryPrompt handles first-run telemetry setup

func WithMetricEmission

func WithMetricEmission(action cli.ActionFunc) cli.ActionFunc

Types

type ActionChain

type ActionChain struct {
	Processors []func(action cli.ActionFunc) cli.ActionFunc
}

func NewActionChain

func NewActionChain() *ActionChain

NewActionChain creates a new action chain

func (*ActionChain) Use

func (ac *ActionChain) Use(processor func(action cli.ActionFunc) cli.ActionFunc)

Use appends a new processor to the chain

func (*ActionChain) Wrap

func (ac *ActionChain) Wrap(action cli.ActionFunc) cli.ActionFunc

Jump to

Keyboard shortcuts

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