1.0.7 โข Published 4 months ago
drizzle-start v1.0.7
๐งฑ drizzle-start
An interactive CLI tool for quick setup of Drizzle ORM in TypeScript projects. Supports PostgreSQL, MySQL, and SQLite with both Bun and Node.js runtimes.
โจ Key Features
- ๐ Interactive setup wizard
- ๐พ Multi-database support (PostgreSQL, MySQL, SQLite)
- ๐ Customizable project structure
- ๐ Automatic dependency installation
- ๐งช Built-in connection testing
- โก Bun-first with Node.js support
๐ Quick Start
# Using bunx (recommended)
bunx drizzle-start
# Using npx
npx drizzle-start
Install in Project
# Bun (recommended)
bun add -D drizzle-start
# npm/yarn/pnpm
npm install -D drizzle-start
yarn add -D drizzle-start
pnpm add -D drizzle-start
Run from Project
bun drizzle-start # Using Bun
npm exec drizzle-start
yarn drizzle-start
pnpm drizzle-start
๐ Project Structure
The CLI creates the following structure (customizable during setup):
your-project/
โโโ src/
โ โโโ database/
โ โโโ db.ts # Database client
โ โโโ schema/ # Schema definitions
โ โ โโโ index.ts
โ โโโ migrations/ # Migration files
โ โโโ tests/ # Connection tests
โโโ .env # Database config
โโโ drizzle.config.ts # Drizzle config
โ๏ธ Configuration
Environment Variables
DB_TYPE=pg|mysql|sqlite
DB_URL=your-connection-string
NPM Scripts
{
"scripts": {
"db:generate": "drizzle-kit generate",
"db:push": "drizzle-kit push",
"db:drop": "drizzle-kit drop",
"db:check": "drizzle-kit check"
}
}
๐ง Requirements
- Bun (recommended) or Node.js 16+
- TypeScript 4+
๐ ๏ธ Development
# Clone repository
git clone https://github.com/yourusername/drizzle-start.git
# Install dependencies
bun install
# Development mode
bun dev
# Build project
bun run build
๐ License
MIT ยฉ Hicham Jebara
๐ Credits
- Clack - Interactive CLI
- Drizzle ORM - Database toolkit
- pm-ninja - Package management
๐ Keywords
drizzle
drizzle-orm
typescript
cli
database
orm
postgresql
mysql
sqlite
bun
nodejs
scaffolding
boilerplate
starter
setup
wizard
interactive
migrations
schema
database-toolkit
development-tools