feat(bootstrap): --demo mode for try-it-out evaluation (M-4) - #29
Merged
Merged
Conversation
scripts/init-project.sh --demo synthesizes a throwaway Node.js source repo (templates/demo-source: 3-file scratch with one git commit) in a temp dir, then delegates to the existing --non-interactive path with an auto-generated config wiring a single backend role at it. Zero prompts, fully-configured sprint-config.yaml + filled be-engineer.md + initialized KB + workflow symlinks. Ready for `/sprint demo-1` in Claude Code. Closes the "can't evaluate zachflow without first having a target codebase" friction from the install/setup review. --demo is mutually exclusive with --from=<file>. The closing banner names the throwaway path so the user can rm -rf it when finished. New tests/demo-mode-test.sh covers happy path, source-repo materialization (.git + 1 commit + role.source wired correctly), cleanup-banner content, and the flag-conflict guard. Wired into CI. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
git-bash's mktemp returns MSYS paths like /tmp/zachflow-demo-config-XXXX, which Windows-native python3 cannot resolve (FileNotFoundError). Pass the DEMO_SOURCE_PATH and DEMO_CONFIG through `cygpath -m` to produce mixed-mode paths (e.g. C:/.../tmp/foo) that both git-bash and native binaries accept. No-op on macOS / Linux. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
demo-mode-test.sh hands $STAGE/sprint-config.yaml to python3 to verify role.source wiring. On Windows runners, git-bash mktemp produces an MSYS path that python3 can't open. Mirror the to_native_path helper from init-project.sh inside the test so $TMPDIR is mixed-mode from the start. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
bash scripts/init-project.sh --demosynthesizes a throwaway Node.js source repo in a temp dir, wires a single backend role at it, and runs the rest of the wizard non-interactively. Zero prompts.templates/demo-source/(3-file scratch: greet() module + test + package.json + README) is the source-of-truth for the throwaway repo.rm -rfcommand.--demois mutually exclusive with--from=<file>(the demo synthesizes its own config).tests/demo-mode-test.shcovers the happy path, throwaway-repo correctness, banner content, and the flag-conflict guard.Why
Install/setup UX review M-4: a new user evaluating zachflow couldn't try it without already having a target codebase pointed at by a
source:path ininit.config.yaml. The barrier to first impression was too high.--demoremoves that barrier — paste one command, get a fully-running zachflow project + a sample to point/sprintat.Test plan
bash tests/demo-mode-test.sh— 3/3 PASS locallybash tests/init-project-smoke.sh— still PASSbash tests/preflight-test.sh— still PASSbash -n scripts/init-project.sh— clean--demo→ sprint-config.yaml + filled teammate + KB + symlinks all present; throwaway source has 1 commit; cleanup banner names the right pathUX flow after this PR
🤖 Generated with Claude Code