add a 'extractor.modules' option
This commit is contained in:
@@ -1,5 +1,7 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## Unreleased
|
||||||
|
|
||||||
## 1.15.2 - 2020-10-24
|
## 1.15.2 - 2020-10-24
|
||||||
### Additions
|
### Additions
|
||||||
- [pinterest] implement login support ([#1055](https://github.com/mikf/gallery-dl/issues/1055))
|
- [pinterest] implement login support ([#1055](https://github.com/mikf/gallery-dl/issues/1055))
|
||||||
|
|||||||
@@ -2225,6 +2225,20 @@ Miscellaneous Options
|
|||||||
=====================
|
=====================
|
||||||
|
|
||||||
|
|
||||||
|
extractor.modules
|
||||||
|
-----------------
|
||||||
|
Type
|
||||||
|
``list`` of ``strings``
|
||||||
|
Default
|
||||||
|
The ``modules`` list in
|
||||||
|
`extractor/__init__.py <../gallery_dl/extractor/__init__.py#L12>`__
|
||||||
|
Example
|
||||||
|
``["reddit", "danbooru", "mangadex"]``
|
||||||
|
Description
|
||||||
|
The list of modules to load when searching for a suitable
|
||||||
|
extractor class. Useful to reduce startup time and memory usage.
|
||||||
|
|
||||||
|
|
||||||
cache.file
|
cache.file
|
||||||
----------
|
----------
|
||||||
Type
|
Type
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
from __future__ import unicode_literals, print_function
|
from __future__ import unicode_literals, print_function
|
||||||
|
|
||||||
__author__ = "Mike Fährmann"
|
__author__ = "Mike Fährmann"
|
||||||
__copyright__ = "Copyright 2014-2018 Mike Fährmann"
|
__copyright__ = "Copyright 2014-2020 Mike Fährmann"
|
||||||
__license__ = "GPLv2"
|
__license__ = "GPLv2"
|
||||||
__maintainer__ = "Mike Fährmann"
|
__maintainer__ = "Mike Fährmann"
|
||||||
__email__ = "mike_faehrmann@web.de"
|
__email__ = "mike_faehrmann@web.de"
|
||||||
@@ -129,6 +129,12 @@ def main():
|
|||||||
for opts in args.options:
|
for opts in args.options:
|
||||||
config.set(*opts)
|
config.set(*opts)
|
||||||
|
|
||||||
|
# extractor modules
|
||||||
|
modules = config.get(("extractor",), "modules")
|
||||||
|
if modules is not None:
|
||||||
|
extractor.modules = modules
|
||||||
|
extractor._module_iter = iter(modules)
|
||||||
|
|
||||||
# loglevels
|
# loglevels
|
||||||
output.configure_logging(args.loglevel)
|
output.configure_logging(args.loglevel)
|
||||||
if args.loglevel >= logging.ERROR:
|
if args.loglevel >= logging.ERROR:
|
||||||
@@ -142,7 +148,7 @@ def main():
|
|||||||
head = ""
|
head = ""
|
||||||
try:
|
try:
|
||||||
out, err = subprocess.Popen(
|
out, err = subprocess.Popen(
|
||||||
("git", "rev-parse", "--short", "HEAD"),
|
("git", "rev-parse", "--short", "HEAD"),
|
||||||
stdout=subprocess.PIPE,
|
stdout=subprocess.PIPE,
|
||||||
stderr=subprocess.PIPE,
|
stderr=subprocess.PIPE,
|
||||||
cwd=os.path.dirname(os.path.abspath(__file__)),
|
cwd=os.path.dirname(os.path.abspath(__file__)),
|
||||||
|
|||||||
@@ -6,4 +6,4 @@
|
|||||||
# it under the terms of the GNU General Public License version 2 as
|
# it under the terms of the GNU General Public License version 2 as
|
||||||
# published by the Free Software Foundation.
|
# published by the Free Software Foundation.
|
||||||
|
|
||||||
__version__ = "1.15.2"
|
__version__ = "1.15.3-dev"
|
||||||
|
|||||||
Reference in New Issue
Block a user