add 'archive-prefix' option (#1711)

pull/1730/head
Mike Fährmann 3 years ago
parent c3b5c88b04
commit 13d4045a8a
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88

@ -569,6 +569,16 @@ Description
.. __: https://docs.python.org/3/library/string.html#format-string-syntax
extractor.*.archive-prefix
--------------------------
Type
``string``
Default
``"{category}"``
Description
Prefix for archive IDs.
extractor.*.postprocessors
--------------------------
Type

@ -1076,9 +1076,9 @@ class DownloadArchive():
# fallback for missing WITHOUT ROWID support (#553)
self.cursor.execute("CREATE TABLE IF NOT EXISTS archive "
"(entry PRIMARY KEY)")
self.keygen = (extractor.category + extractor.config(
"archive-format", extractor.archive_fmt)
self.keygen = (
extractor.config("archive-prefix", extractor.category) +
extractor.config("archive-format", extractor.archive_fmt)
).format_map
def check(self, kwdict):

Loading…
Cancel
Save