diff options
Diffstat (limited to 'BuildTools/Copyrighter.py')
-rwxr-xr-x | BuildTools/Copyrighter.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/BuildTools/Copyrighter.py b/BuildTools/Copyrighter.py index a16050c..4c7bfeb 100755 --- a/BuildTools/Copyrighter.py +++ b/BuildTools/Copyrighter.py @@ -10,3 +10,3 @@ LICENSE_DIR = "Documentation/Licenses" # The following regex parses license comment blocks and its part out of a complete source file. -reParseLicenseCommentBlocks = re.compile(ur'(\/\*\n\s\*\sCopyright \(c\) (?P<startYear>\d\d\d\d)(-(?P<endYear>\d\d\d\d))? (?P<author>[^\n\.]*)\.?\n.\* (?P<license>[^\n]*)\n \* (?P<seeMore>[^\n]+)\n *\*\/)') +reParseLicenseCommentBlocks = re.compile(r'(\/\*\n\s\*\sCopyright \(c\) (?P<startYear>\d\d\d\d)(-(?P<endYear>\d\d\d\d))? (?P<author>[^\n\.]*)\.?\n.\* (?P<license>[^\n]*)\n \* (?P<seeMore>[^\n]+)\n *\*\/)') @@ -124,6 +124,6 @@ def check_copyright(filename, hints) : if hints : - print "Copyright block for " + copyrightSetting.author + " does not cover current year in: " + filename + print("Copyright block for " + copyrightSetting.author + " does not cover current year in: " + filename) return False if hints : - print "Missing copyright block for " + copyrightSetting.author + " in: " + filename + print("Missing copyright block for " + copyrightSetting.author + " in: " + filename) return False @@ -131,3 +131,3 @@ def check_copyright(filename, hints) : if hints : - print "No copyright found in: " + filename + print("No copyright found in: " + filename) return False @@ -142,3 +142,3 @@ def set_or_update_copyright(filename) : if check_copyright(filename, False) : - print "No update required for file: " + filename + print("No update required for file: " + filename) else : @@ -163,3 +163,3 @@ def set_or_update_copyright(filename) : def print_help() : - print """Usage: + print("""Usage: Copyrighter.py check-copyright $filename @@ -174,3 +174,3 @@ def print_help() : $license are default, mit and gpl. - """ + """) @@ -185,3 +185,3 @@ elif sys.argv[1] == "set-copyright" : else : - print "Unknown command: " + sys.argv[1] + print("Unknown command: " + sys.argv[1]) print_help() |