scaffold

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 15, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Package scaffold renders a new builder project.

The sequence matters and is not arbitrary:

  1. togo new — the base app (Go + TanStack + auth + postgres)
  2. fix DB_DRIVER — togo writes "postgres"; its own plugin registers "pgx"
  3. overlay _project — builder's routes, libs, plugin wiring, migrations
  4. overlay _claude — the agent operating system
  5. go.work + tidy — resolve the plugin from the working tree
  6. createdb+migrate — schema before anything tries to read it
  7. seed admin — an app with no way in is not scaffolded, it is bricked
  8. preflight — tell the operator what is missing BEFORE they start

Steps 6–8 are skippable for CI, which wants files on disk and nothing else.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	Name       string
	Dir        string
	Module     string
	AdminEmail string
	DBName     string
	// PluginPath points go.work at a local checkout instead of a published tag.
	// Empty means resolve the published module.
	PluginPath string
	SkipDB     bool
	SkipTidy   bool
	Force      bool
	Out        func(format string, a ...any)
}

type Result

type Result struct {
	Dir       string
	VaultKey  string
	AdminHint string
	Steps     []string
}

func New

func New(project, claude fs.FS, o Options) (*Result, error)

New scaffolds a project.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL