cmd

package
v0.0.0-...-c233a99 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2015 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Runner

type Runner struct {
	// contains filtered or unexported fields
}

Runner will handle parameterizing a command with a given argument and run it, returning the result and exit code

func New

func New(target, scriptTemplate, arg string) Runner

New creates a new command Runner, given a target, script template, and an argument

func (Runner) Run

func (r Runner) Run() (*bytes.Buffer, error)

Run will parameterize the script, run it, and return a reader over its output

type TemplateData

type TemplateData struct {
	Argument string
}

TemplateData is the data available to the command template

Jump to

Keyboard shortcuts

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