1
0
mirror of https://github.com/mikf/gallery-dl.git synced 2024-11-21 18:22:30 +01:00

[noop] insert noop extractor when loading cookies without URL

allows writing --cookies-from-browser results with just
gallery-dl --cookies-from-browser BROWSER --cookies-export DEST
This commit is contained in:
Mike Fährmann 2024-10-28 17:19:47 +01:00
parent 5de8576ff6
commit 4a6e5af28e
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88

View File

@ -252,9 +252,13 @@ def main():
args.input_files.append(input_file)
if not args.urls and not args.input_files:
parser.error(
"The following arguments are required: URL\n"
"Use 'gallery-dl --help' to get a list of all options.")
if args.cookies_from_browser or config.interpolate(
("extractor",), "cookies"):
args.urls.append("noop")
else:
parser.error(
"The following arguments are required: URL\nUse "
"'gallery-dl --help' to get a list of all options.")
if args.list_urls:
jobtype = job.UrlJob