cli

package
v0.0.0-...-3b38f00 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2024 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImportCliHandler

type ImportCliHandler struct {
	ServiceNameFlag `embed:""`
	Comment         string `short:"c" name:"comment" help:"Comment to add in file"`
	Remote          string `short:"r" name:"remote" help:"Remote for which this key should be considered"`
	PrivateKey      string `arg:""`
}

func (ImportCliHandler) AfterApply

func (h ImportCliHandler) AfterApply(kongCtx *kong.Context) error

func (ImportCliHandler) Run

type KeysCliHandler

type KeysCliHandler struct {
	List   ListKeysCliHandler `cmd:"" name:"list" help:"list identities"`
	Import ImportCliHandler   `cmd:"" name:"import" help:"import an identity - currently only x25519 identities are supported"`
}

type ListKeysCliHandler

type ListKeysCliHandler struct {
	ServiceNameFlag `embed:""`
}

func (ListKeysCliHandler) AfterApply

func (h ListKeysCliHandler) AfterApply(kongCtx *kong.Context) error

func (ListKeysCliHandler) Run

func (h ListKeysCliHandler) Run(stdout ports.STDOUT, kr keyring.Keyring) error

type ServeCliHandler

type ServeCliHandler struct {
	ServiceNameFlag `embed:""`
	Http            struct {
		ListenAddress     *url.URL      `default:"unix://${XDG_RUNTIME_DIR}/git-age-keyring-agent.sock"`
		ReadHeaderTimeout time.Duration `default:"5s" help:"Read header timeout"`
		ShutdownTimeout   time.Duration `default:"5s" help:"Shutdown timeout"`
	} `embed:"" prefix:"http."`
}

func (ServeCliHandler) AfterApply

func (h ServeCliHandler) AfterApply(kongCtx *kong.Context) error

func (ServeCliHandler) Run

func (h ServeCliHandler) Run(ctx context.Context, kr keyring.Keyring) (err error)

type ServiceNameFlag

type ServiceNameFlag struct {
	ServiceName string `env:"GIT_AGE_SERVICE_NAME" name:"service.name" short:"s" default:"git-age"`
}

Jump to

Keyboard shortcuts

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