mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-12-02 16:32:51 +01:00
Fix info attachment in subpaths
This commit is contained in:
parent
4b5be635b1
commit
fc349670c3
|
@ -830,6 +830,7 @@ def _get_infojson_opts(self, info, infofn):
|
||||||
info['infojson_filename'] = infofn
|
info['infojson_filename'] = infofn
|
||||||
|
|
||||||
escaped_name = self._ffmpeg_filename_argument(infofn)
|
escaped_name = self._ffmpeg_filename_argument(infofn)
|
||||||
|
info_basename = os.path.basename(infofn)
|
||||||
|
|
||||||
yield (
|
yield (
|
||||||
# In order to override any old info.json reliably we need to
|
# In order to override any old info.json reliably we need to
|
||||||
|
@ -840,8 +841,8 @@ def _get_infojson_opts(self, info, infofn):
|
||||||
# info.json data.
|
# info.json data.
|
||||||
'-map', '-0:m:filename:info.json?',
|
'-map', '-0:m:filename:info.json?',
|
||||||
'-attach', escaped_name,
|
'-attach', escaped_name,
|
||||||
f'-metadata:s:m:filename:{escaped_name}', 'mimetype=application/json',
|
f'-metadata:s:m:filename:{info_basename}', 'mimetype=application/json',
|
||||||
f'-metadata:s:m:filename:{escaped_name}', 'filename=info.json',
|
f'-metadata:s:m:filename:{info_basename}', 'filename=info.json',
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user