Mercurial > hg-stable
comparison tests/test-inherit-mode.t @ 33747:24849d53697d
tests: clean up many print statements to be print functions instead
Differential Revision: https://phab.mercurial-scm.org/D294
author | Augie Fackler <augie@google.com> |
---|---|
date | Thu, 15 Jun 2017 14:22:25 -0400 |
parents | 1bdafe1111ce |
children | 266192d4666b |
comparison
equal
deleted
inserted
replaced
33746:27fb986e54d0 | 33747:24849d53697d |
---|---|
23 > name = os.path.join(root, f) | 23 > name = os.path.join(root, f) |
24 > allnames.append(name) | 24 > allnames.append(name) |
25 > allnames.sort() | 25 > allnames.sort() |
26 > for name in allnames: | 26 > for name in allnames: |
27 > suffix = name in isdir and '/' or '' | 27 > suffix = name in isdir and '/' or '' |
28 > print '%05o %s%s' % (os.lstat(name).st_mode & 07777, name, suffix) | 28 > print('%05o %s%s' % (os.lstat(name).st_mode & 07777, name, suffix)) |
29 > EOF | 29 > EOF |
30 | 30 |
31 $ cat >mode.py <<EOF | 31 $ cat >mode.py <<EOF |
32 > import sys | 32 > import sys |
33 > import os | 33 > import os |
34 > print '%05o' % os.lstat(sys.argv[1]).st_mode | 34 > print('%05o' % os.lstat(sys.argv[1]).st_mode) |
35 > EOF | 35 > EOF |
36 | 36 |
37 $ umask 077 | 37 $ umask 077 |
38 | 38 |
39 $ hg init repo | 39 $ hg init repo |