mod

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Create

type Create struct {
	Name string `arg:"" help:"name of the module to create"`
}

func (*Create) Run

func (c *Create) Run(ctx context.Context, modHandler client.ModHandler, logger log.FLogger) error

type Delete

type Delete struct {
	Name string `arg:"" help:"name of the module to delete"`
}

func (*Delete) Run

func (d *Delete) Run(ctx context.Context, modHandler client.ModHandler, logger log.FLogger) error

type Get

type Get struct {
	Name  string `arg:"" help:"name of the module"`
	Count bool   `name:"count" short:"c" default:"false" help:"return number of results"`
}

func (*Get) Run

func (g *Get) Run(ctx context.Context, modHandler client.ModHandler, logger log.FLogger) error

type List

type List struct {
	Count bool `name:"count" short:"c" default:"false" help:"return number of results"`
}

func (*List) Run

func (l *List) Run(ctx context.Context, modHandler client.ModHandler, logger log.FLogger) error

type Mod

type Mod struct {
	Get    Get    `cmd:"" aliases:"g" help:"list functions and information of a module"`
	Delete Delete `cmd:"" aliases:"d,rm" help:"delete a module"`
	Update Update `cmd:"" aliases:"u,up" help:"update the name of a module"`
	Create Create `cmd:"" aliases:"c" help:"create a new module"`
	List   List   `cmd:"" aliases:"l,ls" help:"list all modules"`
}

func (*Mod) Help

func (f *Mod) Help() string

type ModError

type ModError struct {
	Errors struct {
		Detail string `json:"detail"`
	} `json:"errors"`
}

TODO: avoid repetition, move both ModError and FnError to separate file/package

type Update

type Update struct {
	Name    string `arg:"" help:"name of the module to update"`
	NewName string `arg:"" help:"new name of the module"`
}

func (*Update) Run

func (u *Update) Run(ctx context.Context, modHandler client.ModHandler, logger log.FLogger) error

Jump to

Keyboard shortcuts

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