aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2010-07-14 19:36:25 -0400
committerW. Trevor King <wking@drexel.edu>2010-07-14 19:36:25 -0400
commit3472f94db6fda30ab53c5f1b747095fad1ac3c3b (patch)
tree081093c5677789dcd27fc4b43dc80486df2c056a
parent7fd82c5cebdd035a636d306a888dcf6d319e6b87 (diff)
downloadbugseverywhere-3472f94db6fda30ab53c5f1b747095fad1ac3c3b.tar.gz
Avoid loading the whole bugdir when calling `be html -e`.
This cleans up Mathieu Clabaut's fix to the html_gen definition problems in `be html -e`.
-rw-r--r--libbe/command/html.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/libbe/command/html.py b/libbe/command/html.py
index f4273e9..c61d6d8 100644
--- a/libbe/command/html.py
+++ b/libbe/command/html.py
@@ -104,8 +104,11 @@ class HTML (libbe.command.Command):
])
def _run(self, **params):
- bugdir = self._get_bugdir()
- bugdir.load_all_bugs()
+ if params['export-template'] == True:
+ bugdir = None
+ else:
+ bugdir = self._get_bugdir()
+ bugdir.load_all_bugs()
html_gen = HTMLGen(bugdir,
template=params['template-dir'],
title=params['title'],
@@ -117,7 +120,6 @@ class HTML (libbe.command.Command):
html_gen.write_default_template(params['export-template-dir'])
else:
html_gen.run(params['output'])
- return 0
def _long_help(self):
return """