Skip to main content

Crate offline_generator

Crate offline_generator 

Source
Expand description

§offline-generator

Renders a registry template into a new project directory.

Template contract (registry/templates/<name>/files/):

  • *.tera is rendered (suffix stripped); other files are copied as-is.
  • Underscore-prefixed names map to dotfiles: _gitignore -> .gitignore, _env -> .env, _env.example -> .env.example (also with .tera).
  • Context always includes project_name, versions, and optionally packages.

Modules§

package_json
Edit an existing package.json without reformatting it.
project_detect
Recognise an existing Python, Swift or Gradle (Kotlin/Java) project, so offline init and the MCP init_project tool can wire projects that have no package.json.
project_wiring
.mcp.json and AGENTS.md wiring shared by offline init and the MCP init_project tool.

Structs§

GeneratedProject

Enums§

GeneratorError

Functions§

generate
Generate template_name into target_dir with the given variables.