# z.kuva A web application built with Go, HTMX, Templ, and Tailwind CSS. ## Tech Stack - **Go 1.25** - Backend - **Chi** - HTTP router - **Templ** - HTML templating - **HTMX** - Frontend interactivity - **Tailwind CSS v4** - Styling - **PostgreSQL** - Database ## Prerequisites - Go 1.25+ - [air](https://github.com/cosmtrek/air) for hot reloading - [golang-migrate](https://github.com/golang-migrate/migrate) for database migrations - Docker & Docker Compose - pnpm (for Tailwind CSS) ## Getting Started ### 1. Install dependencies ```bash go mod download pnpm install ``` ### 2. Start PostgreSQL ```bash make db-start ``` This starts a PostgreSQL container using `docker-compose.dev.yaml`: - **Container**: `zkuva-postgres-dev` - **Port**: `5433` (host) → `5432` (container) - **User**: `zkuva` - **Password**: `zkuva` - **Database**: `zkuva_dev` ### 3. Run migrations ```bash make db-migrate ``` ### 4. Start the development server ```bash make dev ``` The app will be available at `http://localhost:3001` ## Makefile Commands ### Development | Command | Description | |---------|-------------| | `make dev` | Start development server with hot-reload | ### Database | Command | Description | |---------|-------------| | `make db-start` | Start PostgreSQL container | | `make db-stop` | Stop PostgreSQL container | | `make db-reset` | Drop & recreate database, then run migrations | | `make db-migrate` | Apply all pending migrations | | `make db-rollback` | Rollback last migration | | `make db-force version=1` | Force migration to specific version | | `make db-version` | Show current migration version | ## Database Connection Connection string for the application: ``` postgres://zkuva:zkuva@localhost:5433/zkuva_dev?sslmode=disable ```