diff options
author | Gregory P. Smith <greg@mad-scientist.com> | 2000-05-12 01:31:37 (GMT) |
---|---|---|
committer | Gregory P. Smith <greg@mad-scientist.com> | 2000-05-12 01:31:37 (GMT) |
commit | ce2b6b838f21f43b1916e607803b956fdee5d2ee (patch) | |
tree | 1b72d768b88282ba7770cb220a641fcf1aee200b /Lib/distutils/cmd.py | |
parent | 147e5f3c65003a753ff545c303bbb039d8ea8ad4 (diff) | |
download | cpython-ce2b6b838f21f43b1916e607803b956fdee5d2ee.zip cpython-ce2b6b838f21f43b1916e607803b956fdee5d2ee.tar.gz cpython-ce2b6b838f21f43b1916e607803b956fdee5d2ee.tar.bz2 |
In 'install_misc' class:
- renamed '_copydata()' to 'copy_files()'
- changed it to record complete output filenames
- dropped '_outputdata()' in favour of much simpler 'get_outputs()'
Diffstat (limited to 'Lib/distutils/cmd.py')
-rw-r--r-- | Lib/distutils/cmd.py | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/Lib/distutils/cmd.py b/Lib/distutils/cmd.py index 3937344..28d8617 100644 --- a/Lib/distutils/cmd.py +++ b/Lib/distutils/cmd.py @@ -8,7 +8,7 @@ in the distutils.command package.""" __revision__ = "$Id$" -import sys, string +import sys, os, string from types import * from distutils.errors import * from distutils import util @@ -355,23 +355,20 @@ class install_misc (Command): self.install_dir = None self.outfiles = None - def _install_dir_from(self, dirname): + def _install_dir_from (self, dirname): self.set_undefined_options('install', (dirname, 'install_dir')) - def _copydata(self, filelist): + def _copy_files (self, filelist): self.outfiles = [] if not filelist: return self.mkpath(self.install_dir) for f in filelist: - self.outfiles.append(self.copy_file (f, self.install_dir)) - - def _outputdata(self, filelist): - if self.outfiles is not None: - return self.outfiles - # XXX de-lambda-fy - return map(lambda x: os.path.join(self.install_dir, x), filelist) + self.copy_file(f, self.install_dir) + self.outfiles.append(os.path.join(self.install_dir, f)) + def get_outputs (self): + return self.outfiles if __name__ == "__main__": |