Commit 9067814c by Chris Jerdonek

Made the argument to pystache.command.render's main() function optional.

parent 0db07048
...@@ -54,7 +54,12 @@ def parse_args(sys_argv, usage): ...@@ -54,7 +54,12 @@ def parse_args(sys_argv, usage):
return template, context return template, context
def main(sys_argv): # TODO: verify whether the setup() method's entry_points argument
# supports passing arguments to main:
#
# http://packages.python.org/distribute/setuptools.html#automatic-script-creation
#
def main(sys_argv=sys.argv):
template, context = parse_args(sys_argv, USAGE) template, context = parse_args(sys_argv, USAGE)
if template.endswith('.mustache'): if template.endswith('.mustache'):
...@@ -77,4 +82,4 @@ def main(sys_argv): ...@@ -77,4 +82,4 @@ def main(sys_argv):
if __name__=='__main__': if __name__=='__main__':
main(sys.argv) main()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment