code: func (a Archive) Add(name, path string) error {
  	if a.gw.Header.Name != "" {
  		return fmt.Errorf("gzip: failed to add %s, only one file can be archived in gz format", name)
  	}
  	file, err := os.Open(path) // #nosec
  	if err != nil {
  		return err
  	}
  	defer file.Close() // nolint: errcheck
  	info, err := file.Stat()
  	if err != nil {
  		return err
  	}
  	if info.IsDir() {
  		return nil
  	}
  	a.gw.Header.Name = name
  	a.gw.Header.ModTime = info.ModTime()
  	_, err = io.Copy(a.gw, file)
  	return err
  }
docs: // Add file to the archive