summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2016-08-20 17:44:54 -0400
committerJason R. Coombs <jaraco@jaraco.com>2016-08-20 17:44:54 -0400
commitb9baa94e18e91671f9acde4e0e033be1391a7fde (patch)
tree70d34911de312c02ea31918dafe1f4fbe22c37ff
parent06df852e7cda567b6f8ab6831486285f0e2989a4 (diff)
downloadpython-setuptools-git-b9baa94e18e91671f9acde4e0e033be1391a7fde.tar.gz
Default to gztar for sdists on all platforms. Ref #748.
-rw-r--r--CHANGES.rst7
-rwxr-xr-xsetuptools/command/sdist.py11
2 files changed, 18 insertions, 0 deletions
diff --git a/CHANGES.rst b/CHANGES.rst
index cd203952..c6839a0d 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -2,6 +2,13 @@
CHANGES
=======
+v26.0.0
+-------
+
+* #748: By default, sdists are now produced in gzipped tarfile
+ format by default on all platforms, adding forward compatibility
+ for the same behavior in Python 3.6 (See Python #27819).
+
v25.4.0
-------
diff --git a/setuptools/command/sdist.py b/setuptools/command/sdist.py
index b6125f58..1d4f5d54 100755
--- a/setuptools/command/sdist.py
+++ b/setuptools/command/sdist.py
@@ -66,6 +66,17 @@ class sdist(orig.sdist):
if data not in dist_files:
dist_files.append(data)
+ def initialize_options(self):
+ orig.sdist.initialize_options(self)
+
+ self._default_to_gztar()
+
+ def _default_to_gztar(self):
+ # only needed on Python prior to 3.6.
+ if sys.version_info >= (3, 6, 0, 'beta', 1):
+ return
+ self.formats = ['gztar']
+
def make_distribution(self):
"""
Workaround for #516