code: def _set_pfiles(dry_run, **kwargs):
      
      pfiles_orig = os.environ['PFILES']
      pfiles = kwargs.get('pfiles', None)
      if pfiles:
          if dry_run:
              print("mkdir %s" % pfiles)
          else:
              try:
                  os.makedirs(pfiles)
              except OSError:
                  pass
          pfiles = "%s:%s" % (pfiles, pfiles_orig)
          os.environ['PFILES'] = pfiles
      return pfiles_orig
docs: Set the PFILES env var
      
      Parameters
      ----------
  
      dry_run : bool
          Don't actually run
  
      Keyword arguments
      -----------------
  
      pfiles : str
          Value to set PFILES
  
      Returns
      -------
  
      pfiles_orig : str
          Current value of PFILES envar