changeset 56:728cae02a6ed

* fix another variable-related bug * API templates may have descriptions (and *should*!)
author Jeff Hammel <jhammel@mozilla.com>
date Thu, 06 Jan 2011 14:25:51 -0800
parents b087a14a664b
children 074a32920f7c
files makeitso/makeitso.py makeitso/template.py
diffstat 2 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/makeitso/makeitso.py	Thu Jan 06 14:15:19 2011 -0800
+++ b/makeitso/makeitso.py	Thu Jan 06 14:25:51 2011 -0800
@@ -200,6 +200,7 @@
         if shebang_re.match(content):
             content = os.linesep.join(content.splitlines()[1:])
 
+        variables = variables or {}
         variables['here'] = parent_uri(uri)
         ContentTemplate.__init__(self, content, name=uri,
                                  interactive=interactive,
--- a/makeitso/template.py	Thu Jan 06 14:15:19 2011 -0800
+++ b/makeitso/template.py	Thu Jan 06 14:25:51 2011 -0800
@@ -50,6 +50,9 @@
     # name of the template
     name = ''
 
+    # description of the template
+    description = ''
+
     # templates to interpolate
     # paths are relative to __file__ unless absolute or URIs
     templates = []