add .claude
This commit is contained in:
92
README.md
92
README.md
@@ -1,92 +0,0 @@
|
|||||||
# Forge - Minimal SaaS Boilerplate
|
|
||||||
|
|
||||||
A data-oriented, no-nonsense SaaS boilerplate following Casey Muratori's principles: solve the problem at hand, avoid premature abstraction, readable over "clean".
|
|
||||||
|
|
||||||
## Stack
|
|
||||||
|
|
||||||
- **Framework**: Quart (async Flask) + Pico CSS
|
|
||||||
- **Database**: SQLite + WAL mode + Litestream replication
|
|
||||||
- **Auth**: Magic link (passwordless)
|
|
||||||
- **Billing**: Stripe (+ optional Paddle)
|
|
||||||
- **Background jobs**: SQLite-based queue (no Redis)
|
|
||||||
- **Deployment**: Docker + Caddy + Hetzner/any VPS
|
|
||||||
|
|
||||||
## Usage
|
|
||||||
|
|
||||||
### Generate a new project
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Install copier
|
|
||||||
pip install copier
|
|
||||||
|
|
||||||
# Generate project
|
|
||||||
copier copy gh:yourusername/forge my-saas
|
|
||||||
|
|
||||||
# Or from local template
|
|
||||||
copier copy ./forge my-saas
|
|
||||||
```
|
|
||||||
|
|
||||||
### Answer the prompts
|
|
||||||
|
|
||||||
```
|
|
||||||
project_slug: my_saas
|
|
||||||
project_name: My SaaS
|
|
||||||
description: A subscription service for widgets
|
|
||||||
author_name: Your Name
|
|
||||||
author_email: you@example.com
|
|
||||||
base_url: https://my-saas.com
|
|
||||||
include_paddle: false
|
|
||||||
```
|
|
||||||
|
|
||||||
## After Generation
|
|
||||||
|
|
||||||
See the generated project's README for setup instructions.
|
|
||||||
|
|
||||||
## Philosophy
|
|
||||||
|
|
||||||
1. **Data-oriented**: Plain SQL, no ORM magic
|
|
||||||
2. **Flat structure**: Domain modules, not enterprise folders
|
|
||||||
3. **Concrete over abstract**: Write code first, extract patterns only when repeated 3+ times
|
|
||||||
4. **SQLite until proven otherwise**: Handles more than you think
|
|
||||||
5. **Server-rendered**: Pico CSS + minimal HTMX, no build step
|
|
||||||
6. **Measure don't assume**: Profile before optimizing
|
|
||||||
|
|
||||||
## Structure
|
|
||||||
|
|
||||||
```
|
|
||||||
padelnomics/
|
|
||||||
src/padelnomics/
|
|
||||||
app.py # Application factory
|
|
||||||
core.py # DB, config, email, shared utils
|
|
||||||
worker.py # Background task processor
|
|
||||||
|
|
||||||
auth/ # Domain: authentication
|
|
||||||
routes.py # Routes + queries + decorators
|
|
||||||
templates/
|
|
||||||
|
|
||||||
billing/ # Domain: subscriptions & payments
|
|
||||||
routes.py
|
|
||||||
templates/
|
|
||||||
|
|
||||||
dashboard/ # Domain: user dashboard
|
|
||||||
routes.py
|
|
||||||
templates/
|
|
||||||
|
|
||||||
public/ # Domain: marketing pages
|
|
||||||
routes.py
|
|
||||||
templates/
|
|
||||||
|
|
||||||
api/ # Domain: REST API
|
|
||||||
routes.py
|
|
||||||
|
|
||||||
templates/ # Shared templates
|
|
||||||
base.html
|
|
||||||
|
|
||||||
migrations/
|
|
||||||
schema.sql
|
|
||||||
migrate.py
|
|
||||||
```
|
|
||||||
|
|
||||||
## License
|
|
||||||
|
|
||||||
MIT
|
|
||||||
@@ -134,7 +134,3 @@ Configure `litestream.yml` with your S3/R2 bucket, then:
|
|||||||
# Run with replication
|
# Run with replication
|
||||||
litestream replicate -config litestream.yml
|
litestream replicate -config litestream.yml
|
||||||
```
|
```
|
||||||
|
|
||||||
## License
|
|
||||||
|
|
||||||
MIT
|
|
||||||
|
|||||||
Reference in New Issue
Block a user