Please sign in to comment.
Add support for generating arbitrary scripts from templates.
Closes #111. This change required pretty substantial changes to the way the `add` command is configured and operates, but all for the good, I think. * Replace the `with_$script` and `$script_template` attributes with `with_scripts` and `templates`, which return hash references mapping scripts to template files. * Add the `--with` option to name a script to generate. Repeplaces the `--deploy`, `--revert`, and `--verify` options. * Add the `--without` option to name a script *not* to generate. Replaces the `--no-deploy`, `--no-revert`, and `--no-verify` options. * Add the `--use` option. Pass in one or more key/value pairs to map script names to their templates. * Replace the `add.deploy_template`, `add.revert_template`, and `add.verify_template` config variables with a section, `add.templates`. * Determine the list of templates by listing the subdirectories of all three template directories, `--template-directory` (or `add.template_directory`), `~/.sqitch/templates`, and `$etc/sqitch/templates`. Any subdirectory of these directories that has a valid template will result in a script being generated in a directory with the same name, unless `--without` excludes it. * Add the `script_file` method to App::Sqitch::Plan::Change, so that we have a uniform way of getting the path to any script file, not just the core three. The core three sill respect `--deploy-dir`, `--revert-dir`, and `--verify-dir`, but any custom scripts have no such luxury
- Loading branch information...
Showing with 531 additions and 262 deletions.
Oops, something went wrong.