Documentation
¶
Overview ¶
Package clone provides embedded app-clone templates for nself init --template. Each template bundles a Postgres schema, Hasura metadata, seed data, and a Flutter UI starter. Templates are embedded in the binary via go:embed so no network access is required at scaffold time.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsCloneTemplate ¶
IsCloneTemplate reports whether name is one of the six bundled clone templates.
Types ¶
type Manifest ¶
type Manifest struct {
Name string `json:"name"`
Version string `json:"version"`
Description string `json:"description"`
RequiredPlugins []string `json:"required_plugins"`
}
Manifest describes a clone template.
func GetManifest ¶
GetManifest reads the manifest.json for the named template.
type ScaffoldOptions ¶
type ScaffoldOptions struct {
// TargetDir is the directory to write files into. It must exist.
TargetDir string
// NoSeed skips 002_seed.sql.
NoSeed bool
// DryRun prints files without writing.
DryRun bool
}
ScaffoldOptions controls how a template is written to disk.
Click to show internal directories.
Click to hide internal directories.