diff options
author | Sergey M․ <dstftw@gmail.com> | 2015-07-11 22:59:18 +0600 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2015-07-11 22:59:18 +0600 |
commit | 1f3a43dbe6b289ff7933754007314c1465e8af7f (patch) | |
tree | 5aedcd5d0c69574944ea1aebdc5aed0a6a5f9bb8 /youtube_dl/postprocessor/common.py | |
parent | d919fa3344463f94a152a10ba65981cd290d9ec8 (diff) | |
parent | 369e195a44530b43bfd0e95087c9e1a238d91184 (diff) |
Merge branch 'aurium-master'
Diffstat (limited to 'youtube_dl/postprocessor/common.py')
-rw-r--r-- | youtube_dl/postprocessor/common.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/youtube_dl/postprocessor/common.py b/youtube_dl/postprocessor/common.py index 3b0e8ddd8..4191d040b 100644 --- a/youtube_dl/postprocessor/common.py +++ b/youtube_dl/postprocessor/common.py @@ -23,6 +23,9 @@ class PostProcessor(object): PostProcessor objects follow a "mutual registration" process similar to InfoExtractor objects. + + Optionally PostProcessor can use a list of additional command-line arguments + with self._configuration_args. """ _downloader = None @@ -57,6 +60,13 @@ class PostProcessor(object): except Exception: self._downloader.report_warning(errnote) + def _configuration_args(self, default=[]): + pp_args = self._downloader.params.get('postprocessor_args') + if pp_args is None: + return default + assert isinstance(pp_args, list) + return pp_args + class AudioConversionError(PostProcessingError): pass |