Cookiecutter generates new projects from templates when copying boilerplate is no longer enough. It prompts for values such as project name, license, author, provider, and version, then inserts those choices into the generated files. section 7.2.1
Cookiecutter extends repository templates in three practical ways:
- Prompts replace manual updates to fields such as project names, licenses, and authors. section 7.2.1
- Template logic conditionally generates files or configuration based on user responses. section 7.2.1
- Generated projects can standardize Terraform modules, root modules, workspaces, and their supporting quality-control configuration. section 7.2.1 section 7.8
Generate a Terraform module
Run `cookiecutter gh:TerraformInDepth/terraform-module-cookiecutter`, answer the six prompts, and receive a project containing files such as `main.tf`, `providers.tf`, `variables.tf`, `README.md`, `.tflint.hcl`, and CI-related configuration. The selected provider can determine which TFLint plugin configuration is created. section 7.2.1
