summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author?ric Araujo <merwok@netwok.org>2011-02-03 17:47:17 +0100
committer?ric Araujo <merwok@netwok.org>2011-02-03 17:47:17 +0100
commit413ddd99169dec7df0715c33113f503ca354ce91 (patch)
tree91f1e3920cbea88e44381eed121e219970d7fbbe
parent95b897fc5eef8a40f8d12ffd2a2bd2f1687fbb73 (diff)
parent892f8f9425abbfeb27a9836e7d481cd6827ae5d7 (diff)
downloaddisutils2-413ddd99169dec7df0715c33113f503ca354ce91.tar.gz
Branch merge
-rw-r--r--distutils2/_backport/shutil.py4
-rw-r--r--distutils2/command/cmd.py9
-rw-r--r--distutils2/tests/test_command_test.py4
-rw-r--r--docs/source/distutils/apiref.rst2
4 files changed, 4 insertions, 15 deletions
diff --git a/distutils2/_backport/shutil.py b/distutils2/_backport/shutil.py
index 17d6728..21f94fb 100644
--- a/distutils2/_backport/shutil.py
+++ b/distutils2/_backport/shutil.py
@@ -376,7 +376,7 @@ def _make_tarball(base_name, base_dir, compress="gzip", verbose=0, dry_run=0,
archive that is being built. If not provided, the current owner and group
will be used.
- The output tar file will be named 'base_dir' + ".tar", possibly plus
+ The output tar file will be named 'base_name' + ".tar", possibly plus
the appropriate compression extension (".gz", or ".bz2").
Returns the output filename.
@@ -451,7 +451,7 @@ def _call_external_zip(base_dir, zip_filename, verbose=False, dry_run=False):
def _make_zipfile(base_name, base_dir, verbose=0, dry_run=0, logger=None):
"""Create a zip file from all the files under 'base_dir'.
- The output zip file will be named 'base_dir' + ".zip". Uses either the
+ The output zip file will be named 'base_name' + ".zip". Uses either the
"zipfile" Python module (if available) or the InfoZIP "zip" utility
(if installed and found on the default search path). If neither tool is
available, raises ExecError. Returns the name of the output zip
diff --git a/distutils2/command/cmd.py b/distutils2/command/cmd.py
index 754fcf4..0e4d99e 100644
--- a/distutils2/command/cmd.py
+++ b/distutils2/command/cmd.py
@@ -10,14 +10,7 @@ import logging
from distutils2.errors import DistutilsOptionError
from distutils2 import util
from distutils2 import logger
-
-# XXX see if we want to backport this
-from distutils2._backport.shutil import copytree, copyfile, move
-
-try:
- from shutil import make_archive
-except ImportError:
- from distutils2._backport.shutil import make_archive
+from distutils2._backport.shutil import copytree, copyfile, move, make_archive
class Command(object):
diff --git a/distutils2/tests/test_command_test.py b/distutils2/tests/test_command_test.py
index 3d6757b..62821ac 100644
--- a/distutils2/tests/test_command_test.py
+++ b/distutils2/tests/test_command_test.py
@@ -17,10 +17,6 @@ from distutils2.command import set_command
from distutils2.dist import Distribution
from distutils2._backport import pkgutil
-try:
- any
-except NameError:
- from distutils2._backport import any
EXPECTED_OUTPUT_RE = r'''FAIL: test_blah \(myowntestmodule.SomeTest\)
----------------------------------------------------------------------
diff --git a/docs/source/distutils/apiref.rst b/docs/source/distutils/apiref.rst
index c43ec2e..6951d84 100644
--- a/docs/source/distutils/apiref.rst
+++ b/docs/source/distutils/apiref.rst
@@ -888,7 +888,7 @@ tarballs or zipfiles.
.. function:: make_zipfile(base_name, base_dir[, verbose=0, dry_run=0])
Create a zip file from all files in and under *base_dir*. The output zip file
- will be named *base_dir* + :file:`.zip`. Uses either the :mod:`zipfile` Python
+ will be named *base_name* + :file:`.zip`. Uses either the :mod:`zipfile` Python
module (if available) or the InfoZIP :file:`zip` utility (if installed and
found on the default search path). If neither tool is available, raises
:exc:`DistutilsExecError`. Returns the name of the output zip file.