Beautiful, minimal CLI for database management.
# Interactive CLI (default)
bun run cli
# Same as above
bun run cli --seed
# Show help
bun run cli --help
# Force rebuild and run
bun run cli:fresh- 🎨 Beautiful colors - No emojis, clean ANSI colors
- ⚡ Smart building - Only rebuilds when needed
- 🎯 Simple commands - Just
bun run cli - 🔮 Future ready - Extensible for more commands
- 🛡️ Robust - Handles non-TTY environments gracefully
- Automatically detects database provider (PostgreSQL, Turso, SQLite)
- Provides appropriate clearing instructions
- Safe operation with clear warnings
- Automatically detects database provider
- Provides correct
drizzle-kit pushcommand - Guides users through schema deployment
- 5 different schema templates (E-commerce, Blog, CRM, Social Media, Task Management)
- Complete SQL schemas with relationships and constraints
- Ready-to-use database structures
- Clear instructions for deployment
- Auto-detects database provider (PostgreSQL, Turso, SQLite)
- Shows provider-specific SQL queries for viewing tables
- Includes table structure and row count queries
- Manual setup instructions for unknown providers
- Comprehensive help with examples
- Database support information
- Troubleshooting guide
apps/drizzleasy/src/cli/
├── index.ts # Main CLI entry
├── cli-manager.ts # Command routing
├── commands/
│ ├── cli-command.ts # Main CLI command
│ ├── clear-database.ts # Database operations
│ ├── generate-schema.ts # Schema generation
│ ├── generate-and-push.ts # Schema push operations
│ └── view-tables.ts # Table viewing utilities
├── ui/
│ ├── colors.ts # ANSI color utilities
│ ├── intro-screen.ts # Branded intro
│ ├── interactive-menu.ts # fzf-style menu
│ └── help-screen.ts # Help documentation
└── types/
└── cli-types.ts # Simple types
- Create command in
commands/ - Add to CLI config in
index.ts - Support
--commandflag automatically
- Zero dependencies - Pure ANSI colors
- Smart caching - Only builds when source changes
- Lightweight - ~17KB bundled size
- Non-TTY safe - Works in CI/CD environments