From a0d96c9843da915bee28c29993d6e1a4e2d21d9f Mon Sep 17 00:00:00 2001 From: Philipp Hagemeister Date: Mon, 9 Dec 2013 04:31:18 +0100 Subject: [PATCH] Add filename to --dump-json output (Fixes #1908) --- youtube_dl/YoutubeDL.py | 1 + 1 file changed, 1 insertion(+) diff --git a/youtube_dl/YoutubeDL.py b/youtube_dl/YoutubeDL.py index fc36be56f..3fbbf3ba0 100644 --- a/youtube_dl/YoutubeDL.py +++ b/youtube_dl/YoutubeDL.py @@ -751,6 +751,7 @@ def process_info(self, info_dict): if self.params.get('forceformat', False): self.to_stdout(info_dict['format']) if self.params.get('forcejson', False): + info_dict['_filename'] = filename self.to_stdout(json.dumps(info_dict)) # Do nothing else if in simulate mode