code: func pgPassFile(cfg abcconfig.DBConfig) (string, error) {
  	tmp, err := ioutil.TempFile("", "pgpass")
  	if err != nil {
  		return "", errors.New("failed to create postgres pass file")
  	}
  	defer tmp.Close()
  
  	fmt.Fprintf(tmp, "%s:%d:%s:%s", cfg.Host, cfg.Port, cfg.DBName, cfg.User)
  	if len(cfg.Pass) != 0 {
  		fmt.Fprintf(tmp, ":%s", cfg.Pass)
  	}
  	fmt.Fprintln(tmp)
  
  	return tmp.Name(), nil
  }
docs: // pgPassFile creates a file in the temp directory containing the connection
  // details and password for the database to be passed into the mysql cmdline cmd