7.4 KiB
phase, plan, subsystem, tags, requires, provides, affects, tech-stack, key-files, key-decisions, patterns-established, requirements-completed, duration, completed
| phase | plan | subsystem | tags | requires | provides | affects | tech-stack | key-files | key-decisions | patterns-established | requirements-completed | duration | completed | ||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 01-framework-kernel-foundation | 03 | kernel |
|
|
|
|
|
|
|
|
|
26min | 2026-09-16 |
Phase 1 Plan 3: Plugin Scaffold, CLI Output and Watch Loop Summary
make:plugin / plugin:add wire a compiling module into summer.yaml, bonfire degrades spinner/progress/table/prompts without a TTY, and summer dev rebuilds through build.App with measured restart latency
Performance
- Duration: 26 min
- Started: 2026-09-16T11:33:58Z
- Completed: 2026-09-16T12:00:25Z
- Tasks: 3
- Files modified: 21
Accomplishments
summer make:pluginscaffoldsplugins/<name>withgo.mod(toolchain go1.27.0),plugin.goand emptyconfig/;plugin:addappends one ordered manifest entry,go work use, and a portable appgo.modrequire/replace- Shared cobra adapter injects one
bonfire.Outputbuilt from stdin/stdout/stderr; non-TTY spinner is[...] message, progress is[N/M] pct%at 10% steps, tables are TSV, andNO_COLOR/TERM=dumbdisable ANSI summer devwatches sources, debounces, callsbuild.App, printsrebuild: <duration>, keeps the last child on build failure, and reaps it on cancel without looping on generatedmain.go/plugins.gen.go
Task Commits
Each task was committed atomically:
- Task 1: Add and rebuild a compiling plugin from the tool -
9b1a25d(feat) - Task 2: Give tool and plugin commands deterministic rich output -
a6004e4(feat) - Task 3: Rebuild and restart the hello binary during source edits -
270b7f1(feat)
Plan metadata: pending (docs: complete plan)
Files Created/Modified
internal/build/manifest.go- Load/Save summer.yaml, lowercase vendor.plugin IDsinternal/build/scaffold.go- MakePlugin / AddPlugin with path containment checksinternal/build/build.go- generate-and-compile plus GOWORK isolation for childgocommandscmd/summer/main.go-make:plugin,plugin:add,build,devtool commandsbonfire/output.go/widgets.go/prompts.go- injected Output, spinner, progress, table, promptsbonfire/root.go/command.go- cobra adapter, namedErrCommandNamefor plugin names without:internal/dev/watch.go- fsnotify watch loop with debounce, serialize, restart, reapexamples/hello/plugins/greeter/plugin.go- table plus confirm ongreeter:hellowithout hanging on closed stdin
Decisions Made
- Keep generated plugin paths under
plugins/<name>derived from the ID's plugin segment - Treat
buildanddevas the only kernel command names allowed without a colon - Detect widgets from stdout TTY and prompts from stdin+stdout TTY so piped tests use defaults
secretusesterm.ReadPasswordon a TTY file and a plain stdin line otherwise; answers are never written back- Watch production path always calls
build.App; tests inject Build/Start so debounce and ignore behavior stay fast
Deviations from Plan
Auto-fixed Issues
1. [Rule 3 - Blocking] Child go commands inherited test GOFLAGS/GOWORK
- Found during: Task 1 (plugin compile on a temp hello copy)
- Issue:
go testsets-mod=readonlyand a parent workspace;go buildof a temp app then targeted the wrong module - Fix: Strip inherited
GOWORK/GOFLAGSand setGOWORKto the nearest appgo.work(oroff) - Files modified:
internal/build/scaffold.go,internal/build/build.go - Verification:
go test ./internal/build - Committed in:
9b1a25d(Task 1)
2. [Rule 3 - Blocking] NewRoot now returns a named command-name error
- Found during: Task 2
- Issue: Plugin names without
namespace:verbmust fail registration; callers and generatedmain.gostill treated NewRoot as a single return - Fix:
NewRoot/NewRootIOreturn(*cobra.Command, error); generateMain and hello callers updated - Files modified:
bonfire/root.go,internal/build/build.go,examples/hello/main.go,examples/hello/hello_test.go,cmd/summer/main.go - Verification:
go test ./bonfire ./cmd/summerand hello tests - Committed in:
a6004e4(Task 2)
3. [Rule 3 - Blocking] Greeter test Output stub no longer satisfied the interface
- Found during: Task 2
- Issue: Expanding Output broke
examples/hello/plugins/greeter/plugin_test.go's three-method stub - Fix: Run the command against
bonfire.NewOutputwith injected streams - Files modified:
examples/hello/plugins/greeter/plugin_test.go - Verification:
go testin the greeter module - Committed in:
a6004e4(Task 2)
Total deviations: 3 auto-fixed (3 blocking) Impact on plan: Required for temp-app builds, named registration errors, and a compiling greeter test. No scope creep. Choice prompts use a numbered list rather than TTY arrow keys; non-TTY behavior matches the plan.
Issues Encountered
go mod tidyin a workspace still dropstoolchain go1.27.0unless it is rewritten; Task 1 restores it after plugin tidy (same D-05 pattern as Plans 01 and 02).
Authentication Gates
None.
User Setup Required
None - no external service configuration required.
Next Phase Readiness
Ready for 01-04-PLAN.md (phase unit-test coverage). Scaffolding, rich CLI output and summer dev exist on the hello path. Do not add HTTP/DB/auth here.
Self-Check: PASSED
- Created scaffold, output, watch, and SUMMARY files exist on disk
- Commits
9b1a25d,a6004e4and270b7f1exist - Root and hello
go vet ./...andgo test ./...passed - STATE.md and ROADMAP.md were not updated in this worktree
Phase: 01-framework-kernel-foundation Completed: 2026-09-16