소스 검색

[YoutubeDL] Improve annotations file naming

Sergey M․ 10 년 전
부모
커밋
98727e123f
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      youtube_dl/YoutubeDL.py

+ 1 - 1
youtube_dl/YoutubeDL.py

@@ -1286,7 +1286,7 @@ class YoutubeDL(object):
                     return
 
         if self.params.get('writeannotations', False):
-            annofn = filename + '.annotations.xml'
+            annofn = replace_extension(filename, 'annotations.xml', info_dict.get('ext'))
             if self.params.get('nooverwrites', False) and os.path.exists(encodeFilename(annofn)):
                 self.to_screen('[info] Video annotations are already present')
             else: