module

Flock::Cli::Templates

Code templates for the files a new project is scaffolded with. Kept as plain string builders (no ECR) so the generated Crystal is easy to read and tweak.

Instance methods

entry(c : Config, base : String) : String

The project entry point: requires the Flock stack + the auto-loaded source dirs, builds the App with the chosen plugins, and applies the Registry (generated systems/startups). base is the relative path from the project's src/ to the Flock ecosystem root, so the generated requires work wherever the project lives.

Source
gitignore
Source
ldtk_map

A self-contained LDtk project: an 8x6 IntGrid level with a solid border and two platforms. Rendered with intgrid: true, each cell is a solid colored quad — no tileset image needed.

Source
readme(c : Config) : String
Source
registry(c : Config) : String

The Registry: generated systems/startups register into it at load time; apply installs them on the App. Generators only ADD files under systems/ — they never edit this.

Source
shard_yml(c : Config, base : String) : String

shard.yml with the Flock shards as path dependencies. base is the relative path from the project root (where this file lands) to the Flock ecosystem root — see Naming.relative_path — so the generated project isn't pinned to the absolute path of the machine it was scaffolded on.

Source