# HG changeset patch # User Jeff Hammel # Date 1294348452 28800 # Node ID d3e1e5745f240eeef36e44fe48add7e940fac3f7 # Parent 599c365d9105ad34666fa0ba3a810ec7f12201f1 pass the variables, fixes tests diff -r 599c365d9105 -r d3e1e5745f24 makeitso/makeitso.py --- a/makeitso/makeitso.py Thu Jan 06 12:29:47 2011 -0800 +++ b/makeitso/makeitso.py Thu Jan 06 13:14:12 2011 -0800 @@ -172,7 +172,7 @@ def substitute(self, **variables): """interactive (for now) substitution""" - vars = self.get_variables() + vars = self.get_variables(**variables) self.check_missing(vars) return self._substitute(**vars) @@ -250,7 +250,7 @@ # find variables from files for f in filenames: path = os.path.join(dirpath, f) - template = URITemplate(path, self.interactive=self.interactive) + template = URITemplate(path, interactive=self.interactive) missed = template.missing(**variables) missing.update(missed) variables.update(dict([(i, '') for i in missed])) @@ -302,7 +302,7 @@ assert templates, "No templates given!" - self.interactive = True + self.interactive = interactive self._templates = templates[:] self.templates = [] self.output = output