cli

package
v0.0.0-...-4f503d8 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RootApp

type RootApp struct {
	// contains filtered or unexported fields
}

func NewRootApp

func NewRootApp(appName, shortDesc, longDesc string) *RootApp

Returns new instance of cli RootApp that acts as base app of cli interface.

func (*RootApp) AddCommand

func (app *RootApp) AddCommand(cmdName, shortDesc, longDesc string, fn func(args []string))

Add command to app

func (*RootApp) Configure

func (app *RootApp) Configure()

Must call this before running calling Execute() method.

func (*RootApp) Execute

func (app *RootApp) Execute()

Execute adds all child commands to the root command and sets flags appropriately.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳