diff options
author | Philipp Hagemeister <phihag@phihag.de> | 2013-12-26 21:55:42 +0100 |
---|---|---|
committer | Philipp Hagemeister <phihag@phihag.de> | 2013-12-26 21:55:42 +0100 |
commit | fd46a318a2425f51f9e4ceb3ef51025241a3ca53 (patch) | |
tree | 326b1aec9e9eb87123ddb5fff5d50458b201a7ea /youtube_dl | |
parent | 5d4f3985be84679f1b2e3b6dbb31b8625a17d598 (diff) |
Print out encoding information in -v (#2046)
Diffstat (limited to 'youtube_dl')
-rw-r--r-- | youtube_dl/__init__.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/youtube_dl/__init__.py b/youtube_dl/__init__.py index c37d28c59..657e3fd07 100644 --- a/youtube_dl/__init__.py +++ b/youtube_dl/__init__.py @@ -44,6 +44,7 @@ __license__ = 'Public Domain' import codecs import getpass +import locale import optparse import os import random @@ -473,6 +474,8 @@ def parseOpts(overrideArguments=None): write_string(u'[debug] System config: ' + repr(_hide_login_info(systemConf)) + '\n') write_string(u'[debug] User config: ' + repr(_hide_login_info(userConf)) + '\n') write_string(u'[debug] Command-line args: ' + repr(_hide_login_info(commandLineConf)) + '\n') + write_string(u'[debug] Encodings: locale %r, fs %r, out %r, pref: %r\n' % + (locale.getpreferredencoding(), sys.getfilesystemencoding(), sys.stdout.encoding, preferredencoding())) return parser, opts, args |