cli

package
v0.8.0-pre Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddFlags

func AddFlags(rootCmd *cobra.Command)

func GetLogger added in v0.7.0

func GetLogger(params *Params) *log.Logger

GetLogger returns a file logger, according to params.

func HandleProfMem added in v0.7.0

func HandleProfMem(logger *log.Logger, p *Params)

func RootCmd

func RootCmd(fn RootFn) *cobra.Command

func StartCpuProfile added in v0.7.0

func StartCpuProfile(logger *log.Logger, p *Params) func()

func StartCpuProfileSrv added in v0.7.0

func StartCpuProfileSrv(ctx context.Context, logger *log.Logger, p *Params)

Types

type Params

type Params struct {
	LogLevel        am.LogLevel
	LogFile         string
	Version         bool
	ServerAddr      string
	DebugAddr       string
	ImportData      string
	StartupMachine  string
	StartupView     string
	StartupTx       int
	EnableMouse     bool
	CleanOnConnect  bool
	SelectConnected bool
	ProfMem         bool
	ProfCpu         bool
	ProfSrv         bool
}

func ParseParams

func ParseParams(cmd *cobra.Command, _ []string) Params

type RootFn

type RootFn func(cmd *cobra.Command, args []string, params Params)

Jump to

Keyboard shortcuts

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