Versions in this module Expand all Collapse all v0 v0.16.3 Nov 29, 2024 Changes in this version + const HOOK_CANNOT_GET_EXIT_STATUS + const HOOK_DOES_NOT_EXIST + const HOOK_GENERIC_ERROR + const HOOK_INVALID_NAME + const HOOK_STAT_FAILED + const HOOK_SUCCESS + const HOOK_VTROOT_ERROR + type Hook struct + ExtraEnv map[string]string + Name string + Parameters []string + func NewHook(name string, params []string) *Hook + func NewHookWithEnv(name string, params []string, env map[string]string) *Hook + func NewSimpleHook(name string) *Hook + func (hook *Hook) Execute() (result *HookResult) + func (hook *Hook) ExecuteAsReadPipe(in io.Reader) (io.Reader, WaitFunc, int, error) + func (hook *Hook) ExecuteAsWritePipe(out io.Writer) (io.WriteCloser, WaitFunc, int, error) + func (hook *Hook) ExecuteOptional() error + type HookResult struct + ExitStatus int + Stderr string + Stdout string + func (hr *HookResult) String() string + type WaitFunc func() (string, error)