mirror of
				https://github.com/yt-dlp/yt-dlp.git
				synced 2025-10-31 22:55:18 +00:00 
			
		
		
		
	PEP8: more applied
This commit is contained in:
		| @@ -76,10 +76,10 @@ def _real_main(argv=None): | ||||
|     if opts.headers is not None: | ||||
|         for h in opts.headers: | ||||
|             if h.find(':', 1) < 0: | ||||
|                 parser.error('wrong header formatting, it should be key:value, not "%s"'%h) | ||||
|                 parser.error('wrong header formatting, it should be key:value, not "%s"' % h) | ||||
|             key, value = h.split(':', 2) | ||||
|             if opts.verbose: | ||||
|                 write_string('[debug] Adding header from command line option %s:%s\n'%(key, value)) | ||||
|                 write_string('[debug] Adding header from command line option %s:%s\n' % (key, value)) | ||||
|             std_headers[key] = value | ||||
|  | ||||
|     # Dump user agent | ||||
| @@ -197,13 +197,13 @@ def _real_main(argv=None): | ||||
|         if opts.outtmpl is not None: | ||||
|             opts.outtmpl = opts.outtmpl.decode(preferredencoding()) | ||||
|     outtmpl = ((opts.outtmpl is not None and opts.outtmpl) | ||||
|             or (opts.format == '-1' and opts.usetitle and '%(title)s-%(id)s-%(format)s.%(ext)s') | ||||
|             or (opts.format == '-1' and '%(id)s-%(format)s.%(ext)s') | ||||
|             or (opts.usetitle and opts.autonumber and '%(autonumber)s-%(title)s-%(id)s.%(ext)s') | ||||
|             or (opts.usetitle and '%(title)s-%(id)s.%(ext)s') | ||||
|             or (opts.useid and '%(id)s.%(ext)s') | ||||
|             or (opts.autonumber and '%(autonumber)s-%(id)s.%(ext)s') | ||||
|             or DEFAULT_OUTTMPL) | ||||
|                or (opts.format == '-1' and opts.usetitle and '%(title)s-%(id)s-%(format)s.%(ext)s') | ||||
|                or (opts.format == '-1' and '%(id)s-%(format)s.%(ext)s') | ||||
|                or (opts.usetitle and opts.autonumber and '%(autonumber)s-%(title)s-%(id)s.%(ext)s') | ||||
|                or (opts.usetitle and '%(title)s-%(id)s.%(ext)s') | ||||
|                or (opts.useid and '%(id)s.%(ext)s') | ||||
|                or (opts.autonumber and '%(autonumber)s-%(id)s.%(ext)s') | ||||
|                or DEFAULT_OUTTMPL) | ||||
|     if not os.path.splitext(outtmpl)[1] and opts.extractaudio: | ||||
|         parser.error('Cannot download a video and extract audio into the same' | ||||
|                      ' file! Use "{0}.%(ext)s" instead of "{0}" as the output' | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Jouke Waleson
					Jouke Waleson