appcontext

package
v0.0.0-...-ddbfcda Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InContext

func InContext(parent context.Context, ac AppContext) context.Context

Types

type AppContext

type AppContext struct {
	FS          whfs.FS
	Config      config.Config
	Resty       *resty.Client
	GlobalPrefs *prefs.GlobalPrefs
	Prefs       prefs.Prefs
	Auth        client.Auth
	// contains filtered or unexported fields
}

func FromContext

func FromContext(c context.Context) AppContext

func New

func New(command string, cfg config.Config) (ac AppContext, err error)

func NewTestContext

func NewTestContext() AppContext

func (AppContext) Logger

func (ac AppContext) Logger() *logrus.Entry

func (AppContext) SavePrefs

func (ac AppContext) SavePrefs() error

Jump to

Keyboard shortcuts

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