code: func (p *Plugin) run(hook, command string, fn *function.Function) error {
  	if command == "" {
  		return nil
  	}
  
  	fn.Log.WithFields(log.Fields{
  		"hook":    hook,
  		"command": command,
  	}).Debug("hook")
  
  	var cmd *exec.Cmd
  	if runtime.GOOS == "windows" {
  		cmd = exec.Command("cmd", "/c", command)
  	} else {
  		cmd = exec.Command("sh", "-c", command)
  	}
  	cmd.Env = os.Environ()
  	cmd.Dir = fn.Path
  
  	b, err := cmd.CombinedOutput()
  	if err != nil {
  		return &HookError{
  			Hook:    hook,
  			Command: command,
  			Output:  string(b),
  		}
  	}
  
  	return nil
  }
docs: // run a hook command.