Repository navigation
feat(nonstop_cli): generate a Claude Code setup and harden the app template - #51
Merged
Merged
Conversation
`nonstop create --template package|app|plugin` run inside a mono-repo now lists the new member under the root `workspace:` and sets `resolution: workspace` in its pubspec, so `dart pub get` accepts it without manual edits. The mono template never registers itself. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…mplate Generated mono-repos now ship a Claude Code boundary for the project: - a root CLAUDE.md (setup, run, commands, strict SOLID and Flutter rules, definition of done, communication rules) and one CLAUDE.md per area and per member, titled with the project name and gated per selected module - .claude/settings.json with command allowlist, a guard that blocks edits to generated files, and a hook that formats edited Dart files - skills: melos-workspace, new-feature, flutter-best-practices, design-system, troubleshooting - package, app and plugin bricks add a starter CLAUDE.md for new members Template fixes found while documenting it: - dashboard no longer imports auth; the app injects the guard and sign-out - sign-out unregisters the device push token when notifications are enabled - an offline Remote Config fetch no longer fails startup - no user ids, emails or names in logs or crash reports - strings via localization and colors via the theme everywhere - dependencies injected through constructors instead of di.get in build - contracts are abstract interface classes; unused dependencies removed - crashlytics, analytics, network, feature_flags and notifications READMEs rewritten from the code; leftover health-specific helpers removed - create-command syntax fixed in the area READMEs - unused material import with dashboard on and auth off Every module combination still renders; all six verify profiles pass lint, 100% line coverage and a web build. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
packages/nonstop_cli/example/nonstop_example is the output of `nonstop create` with every module enabled, including its CLAUDE.md files and .claude setup. It is a reviewable snapshot of what users get, regenerated from the bricks with `melos run generate:nonstop_example` and never edited by hand. The snapshot is excluded from the repo-wide format/analyze run (it has its own workspace and gate) and from the published package via .pubignore. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
`useEmulators` and `baseUrl` exist in every generated project, so the core package doc now lists both regardless of which modules were selected. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ed pubspecs The coverage gate flagged two lines: the templates' "added to the workspace" log and the lookup skipping an unparsable pubspec on the way up. Co-Authored-By: Claude Opus 5.5 <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.
What changes?
Projects generated by
nonstop createnow start with a Claude Code "system boundary": clear rules for how to set up, run, change and troubleshoot the repo.Claude Code setup in every generated mono-repo
CLAUDE.md, titled with the project name and followed by its description, the same way the README starts. It covers setup, run, commands, strict SOLID and Flutter rules, definition of done, troubleshooting, and how to communicate with the user.CLAUDE.mdper area (apps/,features/,packages/,plugins/) and per member (app, auth, dashboard, 11 packages). Each covers public API, layout, rules, common changes, tests and gotchas.features/auth..claude/settings.json:.envand keystores are denied;*.g.dart,*.i69n.dart, generated theme,pubspec.lock);dart formaton every Dart file Claude edits.melos-workspace,new-feature,flutter-best-practices,design-system,troubleshooting.CLAUDE.mdfor new members.CLI
nonstop create --template package|app|plugininside a mono-repo now adds the member to the rootworkspace:list and setsresolution: workspace. Before,dart pub getrejected new members until they were edited by hand.Template fixes found while documenting it
di.getinbuild;abstract interface class;nonstop createsyntax in the area READMEs; an unusedmaterialimport when dashboard is on and auth is off.Example snapshot
packages/nonstop_cli/example/nonstop_exampleis the committed output ofnonstop createwith every module on. Regenerate it withmelos run generate:nonstop_example; never edit it by hand..pubignore).Validation
dart testinpackages/nonstop_cli: 87 passed, including all 512 module combinations and the new workspace tests.dart run tool/verify_template.dart <profile>forfull,default,minimal,auth-only,network-onlyandfirestore-only: lint clean, 100% line coverage andflutter build webfor each.--no-authand--no-notifications: lint clean, 100% coverage.bashprefix on the hook commands.nonstop create demo_pkg --template packageinside the example: the package was added to the workspace,dart pub getresolved, and it got a starterCLAUDE.md.melos lint: no issues.Compatibility
Affected package:
nonstop_cli(bricks and create command). Only newly generated projects change; existing projects are untouched. If you copied older generated code, note these API changes:AssetImage→AppAssetImageenableAutomaticDataCollection→installGlobalErrorHandlersUserMetadatanow has onlyuserIdDependencyInjection.init()removedFeatureFlagis now an interface (its constructor still works)Checklist
docs/RELEASING.md(no new public packages).🤖 Generated with Claude Code