ATXP-242: Update templates in create-project.ts#9
Merged
robdimarco-atxp merged 11 commits intomainfrom Sep 10, 2025
Merged
Conversation
- Create Framework type for type safety and extensibility - Update TEMPLATES to use atxp-express-starter repository - Require app name as first parameter to createProject function - Add command line argument support for framework selection - Remove interactive project name prompt (now uses parameter) - Add proper validation for app name and framework parameters - Update help documentation with new usage examples - Support both npx atxp create and npm create atxp syntax 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add early help flag detection in parseArgs() - Handle both --help and -h flags before command processing - Ensures help is shown when requested with any command 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add git detection utility to check if git is available - Remove interactive git prompt for better UX - Default to git initialization when git is detected - Add --git flag to force git initialization - Add --no-git flag to skip git initialization - Display helpful messages about git detection behavior - Update help documentation with new git options and examples This follows Rails/CRA patterns of smart defaults with override flags. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Replace empty object with properly typed createOptions - Ensures TypeScript interface compliance - All properties explicitly set to undefined for clarity
- Change from --create flag to 'create' command syntax - Pass through all arguments to underlying atxp create command - Update package.json to version 1.1.0 for breaking change - Update atxp dependency to ^1.1.0 - Maintains full compatibility: npm create atxp my-app --no-git Now supports: - npm create atxp my-app - npm create atxp my-app --framework express - npm create atxp my-app --no-git - npm create atxp --help 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Revert version back to 1.0.5 to stay in sync with main package - Use exact version match for atxp dependency (not ^1.1.0) - Wrapper packages should maintain version parity with main package
- Update README.md files to reflect required app name parameter - Add documentation for new --framework, --git, --no-git flags - Update all examples to show new syntax: npx atxp create <app-name> - Fix default port number from 8016 to 8017 in demo docs - Add smart git detection explanation in examples - Ensure npm create atxp examples match new behavior All documented examples verified to work with new implementation. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Create comprehensive README.md for developers working on create-atxp - Document wrapper architecture and data flow - Add detailed testing instructions with examples - Include troubleshooting guide for common issues - Document version management and publishing workflow - Add testing checklist for releases - Explain npm create syntax and how wrapper transforms calls This helps developers understand and maintain the create-atxp wrapper. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Remove unused 'path' import from run-demo.ts - Remove unused 'inquirer' import from create-project.ts (no longer needed after removing interactive prompts) - All linting warnings resolved - Tests and build still pass
## Enhanced Test Coverage ### create-project.test.ts - Expanded project name validation with more test cases - Added Framework type validation tests - Added git options validation tests - Better organized with nested describe blocks ### index.test.ts - Enhanced create mode detection tests - Added comprehensive argument parsing tests - Added framework flag parsing tests - Added git flag parsing tests - Added help flag detection tests ### create-atxp.test.js (NEW) - New test suite for the wrapper package - Tests argument transformation logic - Tests npm create integration flow - Verifies proper command delegation ## Test Statistics - Before: 8 tests across 5 files - After: 17 tests across 6 files - All tests passing ✅ - Complete coverage of new functionality ## Quality Assurance - TypeScript compilation ✅ - Linting passes ✅ - Build process ✅ - All new features covered by tests 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <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
Implements ATXP-242 with comprehensive improvements to the create project functionality
✅ Core Features
atxp-express-exampletoatxp-express-starter--framework)--gitand--no-gitflags✅ Wrapper Package Updates
create-atxpwrapper to support new APInpm create atxpto underlyingatxp createcommand✅ Documentation & Developer Experience
create-atxppackage✅ Quality Assurance
Test Plan Completed
npm run typecheck)npm test- 8/8 tests)npm run lint)--help,-h)npx atxp createandnpm create atxpsyntax supportedcreate-atxpwrapper correctly passes argumentsDeveloper Experience