Cosmetic fiddling.
authorMark Wooding <mdw@distorted.org.uk>
Sat, 24 May 2014 13:00:03 +0000 (14:00 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Sat, 24 May 2014 21:58:27 +0000 (22:58 +0100)
Fixing typos and layout issues.

backend.py
cmd-admin.py
cmd-remote.py
cmdutil.py
service.py
util.py

index 1725d7d..8c4d4d1 100644 (file)
@@ -227,7 +227,7 @@ class FlatFileBackend (object):
           try: OS.unlink(tmp)
           except: pass
 
-    ## If there's a locekfile, then acquire it around the meat of this
+    ## If there's a lockfile, then acquire it around the meat of this
     ## function; otherwise just do the job.
     if me._lock is None:
       doit()
index 8cea8e7..577fe7a 100644 (file)
@@ -128,7 +128,7 @@ def cmd_addacct(user, service, alias = None):
                  user = user, service = service)
     if D.DB.fetchone() is not None:
       raise U.ExpectedError, (
-        400, "User `%s' already has `%s' account" % (user, service))
+        400, "User `%s' already has `%s' account" % (user, service))
     D.DB.execute("""INSERT INTO services (service, user, alias)
                     VALUES ($service, $user, $alias)""",
                  service = service, user = user, alias = alias)
index 6463d53..c8f0aed 100644 (file)
@@ -28,8 +28,7 @@ import subcommand as SC
 import util as U
 
 @SC.subcommand(
-  'set', ['remote'],
-  'Set password for remote service',
+  'set', ['remote'], 'Set password for remote service',
   params = [SC.Arg('service'), SC.Arg('user')])
 def cmd_set_svc(service, user):
   new = U.readline('new password')
@@ -37,8 +36,7 @@ def cmd_set_svc(service, user):
   svc.setpasswd(user, new)
 
 @SC.subcommand(
-  'clear', ['remote'],
-  'Clear password for remote service',
+  'clear', ['remote'], 'Clear password for remote service',
   params = [SC.Arg('service'), SC.Arg('user')])
 def cmd_set_svc(service, user):
   svc = CU.check_service(service)
index a20b8dd..55939e6 100644 (file)
@@ -144,7 +144,7 @@ def matching_items(want, tab, cond = [], tail = '', **kw):
   """
   Generate the matching items from a query constructed dynamically.
 
-  Usually you wouldn't go through this palaver for a static query, but his
+  Usually you wouldn't go through this palaver for a static query, but this
   function helps with building queries in pieces.  WANT should be a list of
   column names we should output, appropriately qualified if there are
   multiple tables; TAB should be a list of table names, in the form `FOO as
index 26406b5..8b1c87b 100644 (file)
@@ -329,9 +329,7 @@ class CommandRemoteService (BasicRemoteService):
   R_PAT = RX.compile('%(.)')
 
   def __init__(me, set, clear, *args, **kw):
-    """
-    Initialize the command remote service.
-    """
+    """Initialize the command remote service."""
     super(CommandRemoteService, me).__init__(*args, **kw)
     me._set = set
     me._clear = clear
diff --git a/util.py b/util.py
index 49bd11f..6384fd5 100644 (file)
--- a/util.py
+++ b/util.py
@@ -551,9 +551,7 @@ class SimpleDBConnection (object):
     return row
 
   def __enter__(me):
-    """
-    Context protocol: begin a transaction.
-    """
+    """Context protocol: begin a transaction."""
     ##PRINT('<<< BEGIN')
     return
   def __exit__(me, exty, exval, tb):