shell

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Git = git{}

Git is a wrapper around common git commands.

View Source
var Quiet = Runner{
	Stdin: os.Stdin,
}

Quiet is a quiet (no output) runner.

View Source
var Verbose = Runner{
	Stdin:  os.Stdin,
	Stdout: os.Stdout,
	Stderr: os.Stderr,
}

Verbose is a verbose (stdin, stdout, stderr) runner.

Functions

This section is empty.

Types

type Buffered

type Buffered struct {
	Runner
	Buffer bytes.Buffer
}

Buffered is a runner which writes on a bytes.Buffer.

func NewBuffered

func NewBuffered() *Buffered

NewBuffered creates a new buffered runner.

type Runner

type Runner struct {
	Stdin  io.Reader
	Stdout io.Writer
	Stderr io.Writer
}

Runner is a shell command runner.

func (Runner) Git

func (r Runner) Git(folder string, args ...string) error

Git runs git commands on the given folder.

func (Runner) Grep

func (r Runner) Grep(userFolder string, re string) error

Grep runs grep on all the plan files in the given folder.

Jump to

Keyboard shortcuts

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