command

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2024 License: BSD-3-Clause Imports: 6 Imported by: 0

README

Command utils

This module is for adding functionality to commands

Say you want a function to take a name, you define the command

command := &cli.Command{
    Name: "some-command"
}

Now before returning if you want to attach an ability to this command

command.Name(command)

This empty wrapping will attribute args[0] to name, and return an error if the name is not found

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Name

func Name(c *cli.Command)

func NameWithDefault

func NameWithDefault(c *cli.Command, def string)

func Names

func Names(c *cli.Command)

func Universe

func Universe(c *cli.Command)

func Universe0

func Universe0(c *cli.Command)

Types

This section is empty.

Jump to

Keyboard shortcuts

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