X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=youtube_dl%2Fpostprocessor%2Fcommon.py;h=599dd1df2b2fa16b05548ef847d41b3d6d7c9560;hb=a5b6102ea893d6943f9ffa9fc0677229c56c99ca;hp=3b0e8ddd8bfed92f2e9043b0adea2655a9e5f67b;hpb=592e97e8550389e22b716eb33c30584aa3a8d656;p=youtube-dl diff --git a/youtube_dl/postprocessor/common.py b/youtube_dl/postprocessor/common.py index 3b0e8ddd8..599dd1df2 100644 --- a/youtube_dl/postprocessor/common.py +++ b/youtube_dl/postprocessor/common.py @@ -4,6 +4,7 @@ import os from ..utils import ( PostProcessingError, + cli_configuration_args, encodeFilename, ) @@ -23,6 +24,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 +61,9 @@ class PostProcessor(object): except Exception: self._downloader.report_warning(errnote) + def _configuration_args(self, default=[]): + return cli_configuration_args(self._downloader.params, 'postprocessor_args', default) + class AudioConversionError(PostProcessingError): pass