code: func (h *Hook) ExtractCommandArgumentsForFile(headers, query, payload *map[string]interface{}) ([]FileParameter, []error) {
  	var args = make([]FileParameter, 0)
  	var errors = make([]error, 0)
  	for i := range h.PassFileToCommand {
  		if arg, ok := h.PassFileToCommand[i].Get(headers, query, payload); ok {
  
  			if h.PassFileToCommand[i].EnvName == "" {
  				// if no environment-variable name is set, fall-back on the name
  				log.Printf("no ENVVAR name specified, falling back to [%s]", EnvNamespace+strings.ToUpper(h.PassFileToCommand[i].Name))
  				h.PassFileToCommand[i].EnvName = EnvNamespace + strings.ToUpper(h.PassFileToCommand[i].Name)
  			}
  
  			var fileContent []byte
  			if h.PassFileToCommand[i].Base64Decode {
  				dec, err := base64.StdEncoding.DecodeString(arg)
  				if err != nil {
  					log.Printf("error decoding string [%s]", err)
  				}
  				fileContent = []byte(dec)
  			} else {
  				fileContent = []byte(arg)
  			}
  
  			args = append(args, FileParameter{EnvName: h.PassFileToCommand[i].EnvName, Data: fileContent})
  
  		} else {
  			errors = append(errors, &ArgumentError{h.PassFileToCommand[i]})
  		}
  	}
  
  	if len(errors) > 0 {
  		return args, errors
  	}
  
  	return args, nil
  }
docs: // ExtractCommandArgumentsForFile creates a list of arguments in key=value
  // format, based on the PassFileToCommand property that is ready to be used
  // with exec.Command().