@@ 80,9 80,9 @@ class cmd_generate(Command):
"""
aliases = ("gen",)
takes_args = ("tarball", "item?")
- takes_options = (opt_config_dir,)
+ takes_options = (opt_config_dir, opt_verbose)
- def run(self, tarball, item=None, config_dir=None):
+ def run(self, tarball, item=None, config_dir=None, verbose=False):
tar = Path(tarball)
if not tar.is_file():
raise SystemExit("Not a file: {!s}".format(tarball))
@@ 100,6 100,8 @@ class cmd_generate(Command):
for name in release.config.files.keys():
suffix = release.file.path.suffix + "." + name
outpath = release.file.path.with_suffix(suffix)
+ if verbose:
+ print("Generating:", outpath)
outpath.write_text(release.render_item(name), encoding="utf-8")