hooks

package
v1.0.0-alpha-99 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2017 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const Build = "build"

Build is 'build' hook

View Source
const Start = "start"

Start is 'start' hook

Variables

View Source
var (
	// ErrMissingHook is used when the hook is missing
	ErrMissingHook = errors.New("Missing hook.")
)

Functions

func Run

func Run(command string) error

Run a process synchronously inheriting stderr and stdout

Types

type HookError

type HookError struct {
	Command string
	Err     error
}

HookError struct

func (HookError) Error

func (he HookError) Error() string

type Hooks

type Hooks struct {
	BeforeBuild string `json:"before_build"`
	Build       string `json:"build"`
	AfterBuild  string `json:"after_build"`
	BeforeStart string `json:"before_start"`
	Start       string `json:"start"`
	AfterStart  string `json:"after_start"`
}

Hooks (after / deploy / main action)

func (*Hooks) Run

func (h *Hooks) Run(hookType string, wdir string, notes ...string) error

Run invokes the hooks for the given hook type on working directory

Jump to

Keyboard shortcuts

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