]> git.madduck.net Git - code/mailplate.git/blobdiff - mailplate

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

use default if not template name specified
[code/mailplate.git] / mailplate
index 439fc73449415edbd2d23fc8139308221d66bf6b..2b0789ddb725fa12c9d5afc76abe6fa48b50ce45 100755 (executable)
--- a/mailplate
+++ b/mailplate
@@ -325,8 +325,11 @@ elif (options.auto or options.menu) and templname:
     sys.exit(posix.EX_USAGE)
 
 elif not templname and not (options.auto or options.menu):
     sys.exit(posix.EX_USAGE)
 
 elif not templname and not (options.auto or options.menu):
-    err('no template specified')
-    sys.exit(posix.EX_USAGE)
+    if default_templname is not None:
+        templname = default_templname
+    else:
+        err('no template specified')
+        sys.exit(posix.EX_USAGE)
 
 elif options.menu:
     err('--menu mode not yet implemented')
 
 elif options.menu:
     err('--menu mode not yet implemented')