implement 'globals' option

This commit is contained in:
Mike Fährmann
2023-02-28 18:18:55 +01:00
parent b14f8d5817
commit d788e6c60c
4 changed files with 101 additions and 3 deletions

View File

@@ -4694,6 +4694,29 @@ Description
or by `extractor.modules`_.
globals
-------
Type
* |Path|_
* ``string``
Example
* ``"~/.local/share/gdl-globals.py"``
* ``"gdl-globals"``
Default
The ``GLOBALS`` dict in
`util.py <../gallery_dl/util.py>`__
Description
Path to or name of an
`importable <https://docs.python.org/3/reference/import.html>`__
Python module whose namespace gets used as an alternative
|globals parameter|__
for compiled Python expressions.
.. |globals parameter| replace:: ``globals`` parameter
.. __: https://docs.python.org/3/library/functions.html#eval
cache.file
----------
Type