Adds PyInstaller build indicator to --version argument

This commit is contained in:
Nikhil Soni 2017-02-18 06:27:06 +05:30
parent 4cec88fc7f
commit 2a461d6b39

View File

@ -37,8 +37,12 @@ def dump_system_info():
except:
pass
bin_indicator = "" # PyInstaller builds indicator, if using precompiled binary
if getattr(sys, 'frozen', False):
bin_indicator = "Precompiled Binary"
data = [
"Mitmproxy version: {} ({})".format(version.VERSION, git_describe),
"Mitmproxy version: {} ({}) {}".format(version.VERSION, git_describe, bin_indicator),
"Python version: {}".format(platform.python_version()),
"Platform: {}".format(platform.platform()),
"SSL version: {}".format(SSL.SSLeay_version(SSL.SSLEAY_VERSION).decode()),