[CalendarServer-changes] [9995] CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands

source_changes at macosforge.org source_changes at macosforge.org
Wed Oct 31 09:05:59 PDT 2012


Revision: 9995
          http://trac.calendarserver.org//changeset/9995
Author:   cdaboo at apple.com
Date:     2012-10-31 09:05:59 -0700 (Wed, 31 Oct 2012)
Log Message:
-----------
Fix issue with variable naming.

Modified Paths:
--------------
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/acl.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/addressbooks.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/calendars.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cat.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cd.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/help.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/history.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/import.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/logging.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/ls.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkadbk.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkcal.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkdir.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mv.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/principal.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/props.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/proxies.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/put.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/query.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quit.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quota.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/rm.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/server.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/sync.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/user.py
    CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/whoami.py

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/acl.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/acl.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/acl.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -37,7 +37,7 @@
         self.subshell = None
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         interactive = False
         path = None
@@ -46,7 +46,7 @@
             opts, args = getopt.getopt(shlex.split(options), 'i')
         except getopt.GetoptError, e:
             print str(e)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         for name, _ignore_value in opts:
@@ -55,12 +55,12 @@
                 interactive = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         elif args:
             path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/addressbooks.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/addressbooks.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/addressbooks.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -27,15 +27,15 @@
         self.cmds = ("addressbooks",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         opts, args = getopt.getopt(shlex.split(options), '')
         if len(opts) != 0:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         ppath = URL(url=args[0]) if args else None
         principal = self.shell.account.getPrincipal(ppath)

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/calendars.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/calendars.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/calendars.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -27,15 +27,15 @@
         self.cmds = ("calendars",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         opts, args = getopt.getopt(shlex.split(options), '')
         if len(opts) != 0:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         ppath = URL(url=args[0]) if args else None
         principal = self.shell.account.getPrincipal(ppath)

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cat.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cat.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cat.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,10 +28,10 @@
         self.cmds = ("cat", "more",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         opts, args = getopt.getopt(shlex.split(options), '')
         if len(opts) or len(args) != 1:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
 
         path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cd.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cd.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/cd.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -27,10 +27,10 @@
         self.cmds = ("cd",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         opts, args = getopt.getopt(shlex.split(options), '')
         if len(opts) or len(args) != 1:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
 
         newpath = args[0]
@@ -47,7 +47,7 @@
             result = self.shell.setWD(os.path.normpath(os.path.join(oldpath, newpath)))
 
         if not result:
-            print "%s: %s No such directory" % (name, options,)
+            print "%s: %s No such directory" % (cmdname, options,)
 
         return result
 

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/help.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/help.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/help.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -26,10 +26,10 @@
         self.cmds = ("help", "?",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         opts, args = getopt.getopt(shlex.split(options), '')
         if len(opts) or len(args) > 1:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
         self.shell.help(cmd=(None if len(args) == 0 else args[0]))
         return True

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/history.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/history.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/history.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -24,9 +24,9 @@
         self.cmds = ("history",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         if options:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
 
         format = "%%0%ds %%s" % (len(self.shell.history),)

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/import.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/import.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/import.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,7 +28,7 @@
         self.cmds = ("import",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         fname = None
         content_type = None
@@ -50,17 +50,17 @@
                     raise WrongOptions
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if not fname:
             print "File name must be provided"
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         elif len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         elif args:
             path = args[0]
@@ -68,11 +68,11 @@
                 path = os.path.join(self.shell.wd, path)
             if not path.endswith("/"):
                 print "Can only POST to a directory: %s" % (path,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
         else:
             print "Path to POST to must be provided"
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         # Read in data
@@ -80,7 +80,7 @@
             data = open(os.path.expanduser(fname), "r").read()
         except IOError:
             print "Unable to read data from file: %s" % (fname,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         resource = URL(url=path)

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/logging.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/logging.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/logging.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -26,13 +26,13 @@
         self.cmds = ("logging",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         opts, args = getopt.getopt(shlex.split(options), '')
         if len(opts) or len(args) > 1:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
         if args and args[0] not in ("on", "off",):
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
 
         if args:

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/ls.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/ls.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/ls.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -31,7 +31,7 @@
         self.cmds = ("ls",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         longlist = False
         path = None
@@ -70,12 +70,12 @@
                 longlist = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         elif args:
             path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkadbk.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkadbk.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkadbk.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,19 +28,19 @@
         self.cmds = ("mkadbk",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         opts, args = getopt.getopt(shlex.split(options), '')
 
         for name, _ignore_value in opts:
 
             print "Unknown option: %s" % (name,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if len(args) != 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkcal.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkcal.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkcal.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,19 +28,19 @@
         self.cmds = ("mkcal",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         opts, args = getopt.getopt(shlex.split(options), '')
 
         for name, _ignore_value in opts:
 
             print "Unknown option: %s" % (name,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if len(args) != 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkdir.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkdir.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mkdir.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,19 +28,19 @@
         self.cmds = ("mkdir",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         opts, args = getopt.getopt(shlex.split(options), '')
 
         for name, _ignore_value in opts:
 
             print "Unknown option: %s" % (name,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if len(args) != 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mv.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mv.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/mv.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -29,7 +29,7 @@
         self.cmds = ("mv", "move",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         opts, args = getopt.getopt(shlex.split(options), 'n')
 
@@ -40,12 +40,12 @@
                 doURLDecode = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) != 2:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         while True:

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/principal.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/principal.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/principal.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,7 +28,7 @@
         self.cmds = ("principal",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         refresh = False
         resolve = True
         principal = None
@@ -48,12 +48,12 @@
                 print_proxies = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 0:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if not principal:

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/props.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/props.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/props.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -29,7 +29,7 @@
         self.cmds = ("props",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         names = False
         all_props = False
@@ -48,12 +48,12 @@
                 names = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         elif args:
             path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/proxies.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/proxies.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/proxies.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -31,7 +31,7 @@
         self.subshell = None
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         interactive = False
         read = False
@@ -42,7 +42,7 @@
             opts, args = getopt.getopt(shlex.split(options), 'irwp:')
         except getopt.GetoptError, e:
             print str(e)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         for name, value in opts:
@@ -57,12 +57,12 @@
                 principal = self.shell.account.getPrincipal(URL(url=value))
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 0:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if interactive:

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/put.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/put.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/put.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -28,7 +28,7 @@
         self.cmds = ("put", "write",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         fname = None
         content_type = "text/plain"
@@ -44,17 +44,17 @@
                 content_type = value
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if not fname:
             print "File name must be provided"
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         elif len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         elif args:
             path = args[0]
@@ -62,19 +62,20 @@
                 path = os.path.join(self.shell.wd, path)
             if path.endswith("/"):
                 print "Cannot PUT to a directory: %s" % (path,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
         else:
             print "Path to PUT to must be provided"
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         # Read in data
+        fname = os.path.expanduser(fname)
         try:
             data = open(fname, "r").read()
         except IOError:
             print "Unable to read data from file: %s" % (fname,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         resource = URL(url=path)

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/query.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/query.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/query.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -31,7 +31,7 @@
         self.cmds = ("query",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         timerange = False
         start = None
@@ -55,12 +55,12 @@
                 data = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         path = args[0] if len(args) else self.shell.wd

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quit.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quit.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quit.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -24,9 +24,9 @@
         self.cmds = ("quit", "exit",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         if options:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
         raise SystemExit("quitting")
 

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quota.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quota.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/quota.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -29,19 +29,19 @@
         self.cmds = ("quota",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         opts, args = getopt.getopt(shlex.split(options), '')
 
         for name, _ignore_value in opts:
 
             print "Unknown option: %s" % (name,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         path = args[0] if len(args) else self.shell.wd

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/rm.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/rm.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/rm.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -29,20 +29,20 @@
         self.cmds = ("rm",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         opts, args = getopt.getopt(shlex.split(options), '')
 
         for name, _ignore_value in opts:
 
             print "Unknown option: %s" % (name,)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         paths = []
         if len(args) == 0:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
 
         while True:

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/server.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/server.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/server.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -24,9 +24,9 @@
         self.cmds = ("server",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         if options:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
         print self.shell.server
         return True

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/sync.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/sync.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/sync.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -30,7 +30,7 @@
         self.cmds = ("sync",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
 
         force = False
 
@@ -42,12 +42,12 @@
                 force = True
             else:
                 print "Unknown option: %s" % (name,)
-                print self.usage(name)
+                print self.usage(cmdname)
                 raise WrongOptions
 
         if len(args) > 1:
             print "Wrong number of arguments: %d" % (len(args),)
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions
         elif args:
             path = args[0]

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/user.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/user.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/user.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -25,9 +25,9 @@
         self.cmds = ("user",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         if options:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
         user = raw_input("New User: ")
         pswd = getpass("New Password: ")

Modified: CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/whoami.py
===================================================================
--- CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/whoami.py	2012-10-29 16:47:31 UTC (rev 9994)
+++ CalDAVClientLibrary/trunk/caldavclientlibrary/browser/commands/whoami.py	2012-10-31 16:05:59 UTC (rev 9995)
@@ -24,9 +24,9 @@
         self.cmds = ("whoami",)
 
 
-    def execute(self, name, options):
+    def execute(self, cmdname, options):
         if options:
-            print self.usage(name)
+            print self.usage(cmdname)
             raise WrongOptions()
         print self.shell.user
         return True
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20121031/91deadc3/attachment-0001.html>


More information about the calendarserver-changes mailing list