Skip to content
This repository was archived by the owner on May 10, 2023. It is now read-only.

Commit 1b12cee

Browse files
committed
[trunk] Set version to 2017.334.p8
1 parent 579e3e0 commit 1b12cee

File tree

4 files changed

+173
-158
lines changed

4 files changed

+173
-158
lines changed

py-compile

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -128,40 +128,42 @@ else
128128
fi
129129

130130
$PYTHON -c "
131-
import sys, os, string, py_compile
131+
from __future__ import print_function
132+
import sys, os, py_compile
132133
133134
files = '''$files'''
134135
135-
print 'Byte-compiling python modules...'
136-
for file in string.split(files):
136+
print('Byte-compiling python modules...')
137+
for file in files.split():
137138
$pathtrans
138139
$filetrans
139140
$outputtrans
140141
if not os.path.exists(filepath) or not (len(filepath) >= 3
141142
and filepath[-3:] == '.py'):
142-
continue
143-
print file,
143+
continue
144+
print(file, end=' ')
144145
sys.stdout.flush()
145146
py_compile.compile(filepath, outputpath + 'c', path)
146-
print" || exit $?
147+
print()" || exit $?
147148

148149
# this will fail for python < 1.5, but that doesn't matter ...
149150
$PYTHON -O -c "
150-
import sys, os, string, py_compile
151+
from __future__ import print_function
152+
import sys, os, py_compile
151153
152154
files = '''$files'''
153-
print 'Byte-compiling python modules (optimized versions) ...'
154-
for file in string.split(files):
155+
print('Byte-compiling python modules (optimized versions) ...')
156+
for file in files.split():
155157
$pathtrans
156158
$filetrans
157159
$outputtrans
158160
if not os.path.exists(filepath) or not (len(filepath) >= 3
159161
and filepath[-3:] == '.py'):
160-
continue
161-
print file,
162+
continue
163+
print(file, end=' ')
162164
sys.stdout.flush()
163165
py_compile.compile(filepath, outputpath + 'o', path)
164-
print" 2>/dev/null || :
166+
print()" 2>/dev/null || :
165167

166168
# Local Variables:
167169
# mode: shell-script

0 commit comments

Comments
 (0)