config

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2018 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Imports []Import `toml:"import"`
	Scripts []Script `toml:"script"`
}

func Read

func Read(path, prefix string) (Config, error)

func (Config) Help

func (c Config) Help(name string) error

func (Config) List

func (c Config) List()

func (Config) Run

func (c Config) Run(name string, args []string) (int, error)

type Import added in v0.0.2

type Import struct {
	Path   string `toml:"path"`
	Prefix string `toml:"prefix"`
}

type Script

type Script struct {
	Name        string `toml:"name"`
	Exec        string `toml:"exec"`
	Args        string `toml:"args"`
	Description string `toml:"description"`
}

func (Script) Help

func (s Script) Help() (help string)

func (Script) Run

func (s Script) Run(args []string) int

Jump to

Keyboard shortcuts

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