cobrax

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hook

type Hook func(cmd *cobra.Command, args []string)

Hook is a type that represents a function that takes a cobra command and its arguments.

func Hooks

func Hooks(handlers ...Hook) Hook

Hooks is a function that takes a variable number of Hook functions and returns a new Hook function. The returned Hook function, when called, will execute all the provided Hook functions in order.

type HookE

type HookE func(cmd *cobra.Command, args []string) error

HookE is a type that represents a function that takes a cobra command and its arguments and returns an error.

func HooksE

func HooksE(handlers ...HookE) HookE

HooksE is a function that takes a variable number of HookE functions and returns a new HookE function. The returned HookE function, when called, will execute all the provided HookE functions in order. If any of the HookE functions return an error, the execution is stopped and the error is returned.

Jump to

Keyboard shortcuts

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