diff --git a/tren.py b/tren.py index ea04de8..af85419 100755 --- a/tren.py +++ b/tren.py @@ -8,7 +8,7 @@ PROGNAME = "tren.py" BASENAME = PROGNAME.split(".py")[0] PROGENV = BASENAME.upper() -RCSID = "$Id: tren.py,v 1.201 2010/03/18 21:54:30 tundra Exp $" +RCSID = "$Id: tren.py,v 1.202 2010/03/18 23:41:46 tundra Exp $" VERSION = RCSID.split()[2] # Copyright Information @@ -137,26 +137,27 @@ # Literals ##### -ARROW = "--->" # Used for formatting renaming messages -ASKDOREST = "!" # Do rest of renaming without asking -ASKNO = "N" # Do not rename current file -ASKQUIT = "q" # Quit renaming all further files -ASKYES = "y" # Rename current file -COMMENT = "#" # Comment character in include files -DEFINST = 0 # Default replacement instance -DEFLEN = 80 # Default output line length -DEFSEP = "=" # Default rename command separator: old=new -DEFSUFFIX = ".backup" # String used to rename existing targets -DEFESC = "\\" # Escape character -INCL = "I" # Include file command line option -INDENT = " " # Indent string for nested messages +ARROW = "--->" # Used for formatting renaming messages +ASKDOREST = "!" # Do rest of renaming without asking +ASKNO = "N" # Do not rename current file +ASKQUIT = "q" # Quit renaming all further files +ASKYES = "y" # Rename current file +COMMENT = "#" # Comment character in include files +DEFINST = 0 # Default replacement instance +DEFLEN = 80 # Default output line length +DEFSEP = "=" # Default rename command separator: old=new +DEFSUFFIX = ".backup" # String used to rename existing targets +DEFESC = "\\" # Escape character +INCL = "I" # Include file command line option +INDENT = " " # Indent string for nested messages NULLESC = "Escape string" # Cannot be null NULLRENSEP = "Old/New separator string" # Cannot be null NULLSUFFIX = "Forced renaming suffix string" # Cannot be null -OPTINTRO = "-" # Option introducer -RANGESEP = ":" # Separator for instance ranges -SINGLEINST = "SINGLEINST" # Indicates a single, not range, replacement instance - +OPTINTRO = "-" # Option introducer +RANGESEP = ":" # Separator for instance ranges +SINGLEINST = "SINGLEINST" # Indicates a single, not range, replacement instance +WINDOWSGROUP = "WindowsGroup" # Returned on Windows w/o win32all +WINDOWSUSER = "WindowsUser" # Reutrned on Windows w/o win32all ##### # Replacement Token Literals @@ -349,7 +350,7 @@ eTOKBADSEQ = "Unknown sequence renaming token, '%s'!" eTOKDELIM = "Renaming token '%s' missing delimiter!" eTOKRANDIG = "Renaming token: '%s' has invalid random precision! Must be integer > 0." -eTOKUNKNOWN = "Renaming token '%s' is unknown type!" +eTOKUNKNOWN = "Unknown renaming token, '%s'!" eTOOMANYINC = "Too many includes! (Max is %d) Possible circular reference?" % MAXINCLUDES @@ -778,7 +779,7 @@ return grp.getgrgid(gid)[0] else: - return "win32group" + return WINDOWSGROUP # End of 'GetFileGroupname()' @@ -793,7 +794,7 @@ return pwd.getpwuid(uid)[0] else: - return "win32user" + return WINDOWSUSER # End of 'GetFileUsername()'