Changeset 919:2ce8ca39525b for diffdist.py
- Timestamp:
- 03/24/19 08:15:59 (5 years ago)
- Branch:
- python3
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
diffdist.py
r310 r919 18 18 def usage(): 19 19 """Print a usage message.""" 20 print "Usage: %s <old dist dir> <new dist dir>" % (sys.argv[0],)20 print("Usage: %s <old dist dir> <new dist dir>" % (sys.argv[0],)) 21 21 22 22 #-------------------------------------------------------------------------- … … 62 62 63 63 if numDiffs<=4: 64 print 65 (path, numDiffs) 64 print("File %s is considered to be the same in both versions with %d changes" % \ 65 (path, numDiffs)) 66 66 finalManifest.addFile(path, oldSize, oldSum) 67 67 copyOld = True 68 68 69 69 if not copyOld: 70 print ">>> File %s is being copied" % (path,)70 print(">>> File %s is being copied" % (path,)) 71 71 tarFile.add(os.path.join(newDirectory, path), arcname = path) 72 72 … … 74 74 with os.fdopen(fd, "wt") as f: 75 75 finalManifest.writeInto(f) 76 os.chmod(path, 0 644)76 os.chmod(path, 0o644) 77 77 tarFile.add(path, arcname = manifestName) 78 78 tarFile.close() … … 80 80 os.remove(path) 81 81 82 print 83 print "%s created" % (tarName,)82 print() 83 print("%s created" % (tarName,)) 84 84 if removed: 85 print 86 print "Files to remove:"87 print 85 print() 86 print("Files to remove:") 87 print() 88 88 for path in removed: 89 print " ", path89 print(" ", path)
Note:
See TracChangeset
for help on using the changeset viewer.