change config specifiers in input file format
Instead of a dictionary/object, input file options are now specified
by a 'key=value' pair starting with '-' for options only applying to
the next URL or '-G' for Global options applying to all following URLs.
See the docstring of parse_inputfile() for details.
Example option specifiers:
- filename = "{id}.{extension}"
- extractor.pixiv.user.directory = ["Pixiv Users", "{user[id]}"]
-spaces="are_optional"
-G keywords = {"global": "option"}
This commit is contained in:
@@ -261,10 +261,9 @@ class ChainPredicate():
|
||||
|
||||
|
||||
class ExtendedUrl():
|
||||
"""URL with attached config dict"""
|
||||
def __init__(self, url, confdict):
|
||||
self.value = url
|
||||
self.config = confdict
|
||||
"""URL with attached config key-value pairs"""
|
||||
def __init__(self, url, gconf, lconf):
|
||||
self.value, self.gconfig, self.lconfig = url, gconf, lconf
|
||||
|
||||
def __str__(self):
|
||||
return self.value
|
||||
|
||||
Reference in New Issue
Block a user