python-fhs
Python module for using the FHS and XDG basedir paths.

◆ write_config()

def fhs.write_config (   name = None,
  text = True,
  dir = False,
  opened = True,
  packagename = None 
)

Open a config file for writing.

The file is not truncated if it exists.

Parameters
nameName of the config file.
textOpen as a text file if True (the default).
dirCreate a directory if True, a file if False (the default).
openedOpen or create the file if True (the default), report the name if False.
packagenameOverride the packagename.
Returns
The opened file, or the name of the file or directory.

Definition at line 160 of file fhs.py.

Here is the caller graph for this function: