annotate Lib/distutils/command/build_scripts.py @ 66807:d28126ebd60d

Entries for datetime, callable, and collections.Counter.
author Raymond Hettinger <python@rcn.com>
date Thu, 09 Dec 2010 16:41:54 +0000
parents 29a3eda89995
children 6ad356525381
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
1 """distutils.command.build_scripts
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
2
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
3 Implements the Distutils 'build_scripts' command."""
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
4
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
5 __revision__ = "$Id$"
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
6
45471
7dd2c1746267 Merged revisions 60990-61002 via svnmerge from
Christian Heimes <christian@cheimes.de>
parents: 44441
diff changeset
7 import os, re
27355
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
8 from stat import ST_MODE
63136
29a3eda89995 reverted distutils its 3.1 state. All new work is now happening in disutils2, and distutils is now feature-frozen.
Tarek Ziadé <ziade.tarek@gmail.com>
parents: 58558
diff changeset
9 from distutils import sysconfig
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
10 from distutils.core import Command
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
11 from distutils.dep_util import newer
49911
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
12 from distutils.util import convert_path, Mixin2to3
23668
ca87119255eb Make setup.py less chatty by default.
Jeremy Hylton <jeremy@alum.mit.edu>
parents: 22082
diff changeset
13 from distutils import log
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
14
18831
132c4bfdba74 Undo revision 1.7: always mangle a #! line containing "python" to point
Greg Ward <gward@python.net>
parents: 16956
diff changeset
15 # check if Python is called on the first line with this expression
29621
ded9abcb9174 Do not add extra "\n" after bang line.
Gustavo Niemeyer <gustavo@niemeyer.net>
parents: 27520
diff changeset
16 first_line_re = re.compile('^#!.*python[0-9.]*([ \t].*)?$')
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
17
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
18 class build_scripts(Command):
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
19
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
20 description = "\"build\" scripts (copy and fixup #! line)"
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
21
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
22 user_options = [
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
23 ('build-dir=', 'd', "directory to \"build\" (copy) to"),
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
24 ('force', 'f', "forcibly build everything (ignore file timestamps"),
33266
4e9ecbf47b6b Patch #736857, #736859: Add -e option to build_scripts.
Martin v. Löwis <martin@v.loewis.de>
parents: 32736
diff changeset
25 ('executable=', 'e', "specify final destination interpreter path"),
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
26 ]
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
27
14829
b1f220f636ed Added 'boolean_options' list to support config file parsing.
Greg Ward <gward@python.net>
parents: 13725
diff changeset
28 boolean_options = ['force']
b1f220f636ed Added 'boolean_options' list to support config file parsing.
Greg Ward <gward@python.net>
parents: 13725
diff changeset
29
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
30
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
31 def initialize_options(self):
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
32 self.build_dir = None
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
33 self.scripts = None
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
34 self.force = None
33266
4e9ecbf47b6b Patch #736857, #736859: Add -e option to build_scripts.
Martin v. Löwis <martin@v.loewis.de>
parents: 32736
diff changeset
35 self.executable = None
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
36 self.outfiles = None
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
37
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
38 def finalize_options(self):
14948
7acb8bbc215b Standardized whitespace around function calls.
Greg Ward <gward@python.net>
parents: 14829
diff changeset
39 self.set_undefined_options('build',
7acb8bbc215b Standardized whitespace around function calls.
Greg Ward <gward@python.net>
parents: 14829
diff changeset
40 ('build_scripts', 'build_dir'),
33266
4e9ecbf47b6b Patch #736857, #736859: Add -e option to build_scripts.
Martin v. Löwis <martin@v.loewis.de>
parents: 32736
diff changeset
41 ('force', 'force'),
4e9ecbf47b6b Patch #736857, #736859: Add -e option to build_scripts.
Martin v. Löwis <martin@v.loewis.de>
parents: 32736
diff changeset
42 ('executable', 'executable'))
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
43 self.scripts = self.distribution.scripts
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
44
31852
2cfe14275a04 backport fix for SF bug #796042: sdist ignores scripts argument in setup
Fred Drake <fdrake@acm.org>
parents: 29621
diff changeset
45 def get_source_files(self):
2cfe14275a04 backport fix for SF bug #796042: sdist ignores scripts argument in setup
Fred Drake <fdrake@acm.org>
parents: 29621
diff changeset
46 return self.scripts
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
47
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
48 def run(self):
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
49 if not self.scripts:
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
50 return
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
51 self.copy_scripts()
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
52
16956
a1b3446c720f When not copying a file because the output is up to date, make the message
Fred Drake <fdrake@acm.org>
parents: 16846
diff changeset
53
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
54 def copy_scripts(self):
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
55 """Copy each script listed in 'self.scripts'; if it's marked as a
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
56 Python script in the Unix way (first line matches 'first_line_re',
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
57 ie. starts with "\#!" and contains "python"), then adjust the first
13725
449dd3a00bd7 Fixed a grab-bag of typos spotted by Rob Hooft.
Greg Ward <gward@python.net>
parents: 12752
diff changeset
58 line to refer to the current Python interpreter as we copy.
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
59 """
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
60 self.mkpath(self.build_dir)
27355
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
61 outfiles = []
49911
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
62 updated_files = []
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
63 for script in self.scripts:
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
64 adjust = False
18871
1b09a9cb06d5 Do convert_path() on script paths (now PyXML builds out of the box
Just van Rossum <just@letterror.com>
parents: 18831
diff changeset
65 script = convert_path(script)
12752
7b49334a6369 Take the basename of the script before concatenating it with the build dir.
Greg Ward <gward@python.net>
parents: 12748
diff changeset
66 outfile = os.path.join(self.build_dir, os.path.basename(script))
27355
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
67 outfiles.append(outfile)
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
68
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
69 if not self.force and not newer(script, outfile):
23668
ca87119255eb Make setup.py less chatty by default.
Jeremy Hylton <jeremy@alum.mit.edu>
parents: 22082
diff changeset
70 log.debug("not copying %s (up-to-date)", script)
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
71 continue
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
72
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
73 # Always open the file, but ignore failures in dry-run mode --
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
74 # that way, we'll get accurate feedback if we can read the
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
75 # script.
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
76 try:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
77 f = open(script, "r")
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
78 except IOError:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
79 if not self.dry_run:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
80 raise
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
81 f = None
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
82 else:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
83 first_line = f.readline()
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
84 if not first_line:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
85 self.warn("%s is an empty file (skipping)" % script)
12745
dad205d13bb5 Bastian Kleineidam: the "build_scripts" command.
Greg Ward <gward@python.net>
parents:
diff changeset
86 continue
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
87
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
88 match = first_line_re.match(first_line)
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
89 if match:
43026
a6d3930b5613 General cleanup, raise normalization in Lib/distutils.
Collin Winter <collinw@gmail.com>
parents: 42084
diff changeset
90 adjust = True
21355
003dc573b295 Joe VanAndel wrote:
Marc-André Lemburg <mal@egenix.com>
parents: 21330
diff changeset
91 post_interp = match.group(1) or ''
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
92
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
93 if adjust:
23668
ca87119255eb Make setup.py less chatty by default.
Jeremy Hylton <jeremy@alum.mit.edu>
parents: 22082
diff changeset
94 log.info("copying and adjusting %s -> %s", script,
ca87119255eb Make setup.py less chatty by default.
Jeremy Hylton <jeremy@alum.mit.edu>
parents: 22082
diff changeset
95 self.build_dir)
49911
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
96 updated_files.append(outfile)
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
97 if not self.dry_run:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
98 outf = open(outfile, "w")
63136
29a3eda89995 reverted distutils its 3.1 state. All new work is now happening in disutils2, and distutils is now feature-frozen.
Tarek Ziadé <ziade.tarek@gmail.com>
parents: 58558
diff changeset
99 if not sysconfig.python_build:
32736
c3a096bfbd6b Whitespace normalization, via reindent.py.
Tim Peters <tim.peters@gmail.com>
parents: 31852
diff changeset
100 outf.write("#!%s%s\n" %
33266
4e9ecbf47b6b Patch #736857, #736859: Add -e option to build_scripts.
Martin v. Löwis <martin@v.loewis.de>
parents: 32736
diff changeset
101 (self.executable,
21330
4420a4bd96a4 Fix for
Michael W. Hudson <mwh@python.net>
parents: 21271
diff changeset
102 post_interp))
4420a4bd96a4 Fix for
Michael W. Hudson <mwh@python.net>
parents: 21271
diff changeset
103 else:
29621
ded9abcb9174 Do not add extra "\n" after bang line.
Gustavo Niemeyer <gustavo@niemeyer.net>
parents: 27520
diff changeset
104 outf.write("#!%s%s\n" %
21330
4420a4bd96a4 Fix for
Michael W. Hudson <mwh@python.net>
parents: 21271
diff changeset
105 (os.path.join(
63136
29a3eda89995 reverted distutils its 3.1 state. All new work is now happening in disutils2, and distutils is now feature-frozen.
Tarek Ziadé <ziade.tarek@gmail.com>
parents: 58558
diff changeset
106 sysconfig.get_config_var("BINDIR"),
29a3eda89995 reverted distutils its 3.1 state. All new work is now happening in disutils2, and distutils is now feature-frozen.
Tarek Ziadé <ziade.tarek@gmail.com>
parents: 58558
diff changeset
107 "python%s%s" % (sysconfig.get_config_var("VERSION"),
29a3eda89995 reverted distutils its 3.1 state. All new work is now happening in disutils2, and distutils is now feature-frozen.
Tarek Ziadé <ziade.tarek@gmail.com>
parents: 58558
diff changeset
108 sysconfig.get_config_var("EXE"))),
21330
4420a4bd96a4 Fix for
Michael W. Hudson <mwh@python.net>
parents: 21271
diff changeset
109 post_interp))
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
110 outf.writelines(f.readlines())
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
111 outf.close()
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
112 if f:
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
113 f.close()
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
114 else:
44441
b91ca87e6f32 Merged revisions 59666-59679 via svnmerge from
Christian Heimes <christian@cheimes.de>
parents: 43400
diff changeset
115 if f:
b91ca87e6f32 Merged revisions 59666-59679 via svnmerge from
Christian Heimes <christian@cheimes.de>
parents: 43400
diff changeset
116 f.close()
49911
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
117 updated_files.append(outfile)
12748
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
118 self.copy_file(script, outfile)
eb562df0cebe Improvements to Bastian's build_scripts command:
Greg Ward <gward@python.net>
parents: 12745
diff changeset
119
27355
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
120 if os.name == 'posix':
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
121 for file in outfiles:
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
122 if self.dry_run:
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
123 log.info("changing mode of %s", file)
dc6116278259 Change the mode of scripts in the build/scripts* directory to
Guido van Rossum <guido@python.org>
parents: 26285
diff changeset
124 else:
42084
229c28cb9afb Merged revisions 55817-55961 via svnmerge from
Guido van Rossum <guido@python.org>
parents: 33965
diff changeset
125 oldmode = os.stat(file)[ST_MODE] & 0o7777
229c28cb9afb Merged revisions 55817-55961 via svnmerge from
Guido van Rossum <guido@python.org>
parents: 33965
diff changeset
126 newmode = (oldmode | 0o555) & 0o7777
27520
6786e86b8ff0 Only log a message and chmod() when the mode isn't already what we
Guido van Rossum <guido@python.org>
parents: 27355
diff changeset
127 if newmode != oldmode:
6786e86b8ff0 Only log a message and chmod() when the mode isn't already what we
Guido van Rossum <guido@python.org>
parents: 27355
diff changeset
128 log.info("changing mode of %s from %o to %o",
6786e86b8ff0 Only log a message and chmod() when the mode isn't already what we
Guido van Rossum <guido@python.org>
parents: 27355
diff changeset
129 file, oldmode, newmode)
6786e86b8ff0 Only log a message and chmod() when the mode isn't already what we
Guido van Rossum <guido@python.org>
parents: 27355
diff changeset
130 os.chmod(file, newmode)
49911
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
131 # XXX should we modify self.outfiles?
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
132 return outfiles, updated_files
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
133
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
134 class build_scripts_2to3(build_scripts, Mixin2to3):
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
135
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
136 def copy_scripts(self):
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
137 outfiles, updated_files = build_scripts.copy_scripts(self)
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
138 if not self.dry_run:
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
139 self.run_2to3(updated_files)
60e775eaaaee Issue #4073: Add 2to3 support to build_scripts, refactor that support
Martin v. Löwis <martin@v.loewis.de>
parents: 45471
diff changeset
140 return outfiles, updated_files