Package Exports
- create-cms-nova
- create-cms-nova/create-cms-nova.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (create-cms-nova) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
🚀 Create CMS Nova
The fastest way to create a modern headless CMS
Build powerful content management systems with Next.js, Prisma, and Better Auth
🚀 Quick Start
Get your CMS up and running in under 2 minutes:
npx create-cms-nova my-cms
cd my-cmsSetup & Launch
# 1. Configure your database
cp .env.example .env
# Edit DATABASE_URL in .env
# 2. Initialize database
npx prisma db push
npx prisma generate
# 3. Start development server
npm run devFirst Steps
- 🌐 Visit http://localhost:3000 → Redirects to admin setup
- 👤 Go to /admin/signup → Create your first admin account
- 🎛️ Access /admin → Full-featured dashboard
- 🎉 You're ready to build!
✨ Features
🎯 Core CMS
|
🔐 Admin & Security
|
🎨 Design & UX
|
🚀 Developer Experience
|
🛠️ Tech Stack
| Category | Technology | Version |
|---|---|---|
| Framework | Next.js | 15+ |
| Runtime | React | 19+ |
| Language | TypeScript | 5+ |
| Database | Prisma ORM | Latest |
| Auth | Better Auth | Latest |
| Styling | Tailwind CSS | 3+ |
| Deployment | Vercel/Railway | - |
📁 Project Structure
my-cms/
├── 📱 src/app/ # Next.js App Router
│ ├── 🔐 admin/ # Admin dashboard
│ ├── 🌐 api/ # REST API routes
│ └── 📄 (pages)/ # Public pages
├── 🧩 src/components/ # Reusable components
│ ├── 🎛️ admin/ # Admin UI components
│ ├── 📝 cms/ # CMS core components
│ └── 🎨 ui/ # Base UI components
├── 🗄️ prisma/ # Database schema & migrations
├── 🔧 src/lib/ # Utilities & configurations
└── 📊 src/types/ # TypeScript definitions🚀 Available Scripts (generated project)
# Development
npm run dev # Start development server
npm run build # Build for production
npm run start # Start production server
# Database
npm run db:generate # Generate Prisma client
npm run db:push # Push schema to database
npm run db:migrate # Run database migrations
npm run db:studio # Open Prisma Studio
npm run db:seed # Seed database with sample data
# Code Quality
npm run lint # Run ESLint
npm run type-check # Run TypeScript checks🌐 Environment Variables (generated project)
Create a .env file in the generated project root:
# Database
DATABASE_URL="postgresql://username:password@localhost:5432/cms_nova"
# Authentication
BETTER_AUTH_SECRET="your-secret-key"
BETTER_AUTH_URL="http://localhost:3000"
# AWS S3 (Optional)
AWS_ACCESS_KEY_ID="your-access-key"
AWS_SECRET_ACCESS_KEY="your-secret-key"
AWS_REGION="us-east-1"
AWS_S3_BUCKET="your-bucket-name"
# Next.js
NEXT_PUBLIC_APP_URL="http://localhost:3000"🧩 Additional Tech (template)
- UI Components: Radix UI-based custom components
- File Upload: AWS S3 integration
🎯 Use Cases
| Blog/News | E-commerce | Portfolio | Documentation |
|---|---|---|---|
| Articles, categories, tags | Products, inventory | Projects, galleries | Guides, tutorials |
| Author management | Order processing | Client testimonials | Version control |
| SEO optimization | Payment integration | Contact forms | Search functionality |
📚 Documentation
🔄 Upgrade Guide
Keep your generated CMS project up to date with the template.
How it works
- Source: Pulls from the template repository configured as
upstream(defaults todanielcadev/cms-nova-template). - Target ref: Uses
upstream/mainby default. You can set another ref via--tag(branch, tag, or commit SHA). - Backup: Creates a backup Git tag automatically before applying changes.
- Clean tree: Requires a clean working tree (commit or stash before upgrading).
You can override the template repository by creating a .cms-nova.json in your project root:
{
"templateRepo": "https://github.com/your-org/your-template.git"
}Default behavior (paths mode)
By default, the upgrade syncs only specific directories/files from the template to avoid overwriting local assets unintentionally. The default paths include:
- .github, .vscode, .eslintrc.json, eslint.config.mjs, tsconfig.json
- next.config.js, next.config.mjs, tailwind.config.js, postcss.config.js, .env.example
- scripts, package.json
- public, prisma
- src, app, src/app, src/admin, admin
Basic commands
- Preview changes:
npx create-cms-nova upgrade --dry-run- Apply changes:
npx create-cms-nova upgradeAdvanced usage
- Specify a template ref (branch, tag, or SHA):
npx create-cms-nova upgrade --tag upstream/dev
npx create-cms-nova upgrade --tag v4.0.5
npx create-cms-nova upgrade --tag c12ddcfc63edbcb3ae6e125d81af22c29b726644- Limit to custom paths:
npx create-cms-nova upgrade --paths "src/components/admin,docker,docs"- Merge mode (pull all template history and resolve conflicts if any):
npx create-cms-nova upgrade --mode mergeDefault diff range (last commit)
- By default, upgrade compares only the last commit from the template ref (e.g.,
upstream/main~1..upstream/main). - To compare a specific range, use:
--since <ref>(e.g.,--since v4.2.0). - To compare the full history, disable the default:
--last-commit false.
Examples:
npx create-cms-nova upgrade # last commit by default
npx create-cms-nova upgrade --since v4.0.5 # since specific tag/commit
npx create-cms-nova upgrade --last-commit falseCommit messages
The CLI includes upgrade metadata in the commit message:
- source: template ref used (e.g.,
upstream/main) - range: comparison range (e.g.,
upstream/main~1..upstream/main) - paths: only in non-interactive paths mode
- summary: only in interactive mode (counts by M/A/D/R)
- backup: created backup tag (if enabled)
- prisma:
schemaand/ormigrationsif changes detected
Prisma changes notice
If the upgrade detects changes in prisma/schema.prisma or prisma/migrations/*, it prints a one-time guidance:
npx prisma migrate reset
npx prisma generate && npx prisma db pushRecommended workflow
- Commit your change to the template repository (e.g.,
cms-nova-templateon the desired branch). - In your generated project, run the upgrade (optionally against the specific ref with
--tag). - Review and test the changes.
Tip: You can run the local script directly (useful when developing the CLI):
node create-cms-nova.js upgrade --dry-run
node create-cms-nova.js upgrade🤝 Community & Support
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
Built with ❤️ by Daniel CA
Star ⭐ this repo if you find it helpful!