aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/command/egg_info.py
diff options
context:
space:
mode:
authoryyfeng88625@gmail.com <yyfeng88625@gmail.com>2014-03-21 13:43:54 +0800
committeryyfeng88625@gmail.com <yyfeng88625@gmail.com>2014-03-21 13:43:54 +0800
commitcb2fa7e5dd86949a06dcdb3babdecc778985fd02 (patch)
tree38c210f35b0d579b144ce2035bd5f4f3c50d97d7 /setuptools/command/egg_info.py
parent6c6fcae287fa60c959b0e63f60b0d12318e0f9f8 (diff)
downloadexternal_python_setuptools-cb2fa7e5dd86949a06dcdb3babdecc778985fd02.tar.gz
external_python_setuptools-cb2fa7e5dd86949a06dcdb3babdecc778985fd02.tar.bz2
external_python_setuptools-cb2fa7e5dd86949a06dcdb3babdecc778985fd02.zip
Python2.x needs encode as well.
--HG-- extra : source : ab82442e2205a4ab1016711e482388590688fa15
Diffstat (limited to 'setuptools/command/egg_info.py')
-rwxr-xr-xsetuptools/command/egg_info.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/setuptools/command/egg_info.py b/setuptools/command/egg_info.py
index 4f5c9694..30873e19 100755
--- a/setuptools/command/egg_info.py
+++ b/setuptools/command/egg_info.py
@@ -304,8 +304,7 @@ def write_file(filename, contents):
sequence of strings without line terminators) to it.
"""
contents = "\n".join(contents)
- if sys.version_info >= (3,):
- contents = contents.encode("utf-8")
+ contents = contents.encode("utf-8")
f = open(filename, "wb") # always write POSIX-style manifest
f.write(contents)
f.close()