# btcprice Bitcoin price tracker - Clojure Kit web application. ## Build & Development Commands - `make run` — Start dev server on port 3000 - `make repl` — Start nREPL on port 7888 - `make test` — Run tests - `make tailwind` — Watch Tailwind CSS for changes - `make uberjar` — Build production JAR - `docker compose up -d` — Start PostgreSQL ## REPL Commands ```clojure (dev-prep!) ;; Prepare dev system (go) ;; Start system (reset) ;; Reload code & restart (halt) ;; Stop system (reset-db) ;; Drop & re-migrate database (migrate) ;; Run pending migrations (rollback) ;; Rollback last migration (query-fn) ;; Get database query function ``` ## Architecture - **Framework:** Kit (Integrant-based) - **Server:** Undertow - **Routing:** Reitit - **Templates:** Hiccup + HTMX - **Styling:** Tailwind CSS v4 - **Database:** PostgreSQL + conman + Migratus ## Source Layout ``` src/clj/pmagnus/btcprice/ ├── core.clj # App entry point ├── config.clj # System config loader └── web/ ├── handler.clj # Ring handler + routes ├── htmx.clj # page/fragment macros ├── controllers/ │ └── health.clj # Health check ├── middleware/ │ ├── core.clj # Base middleware │ ├── exception.clj # Exception handling │ └── formats.clj # Content negotiation └── routes/ ├── api.clj # /api routes (JSON) ├── ui.clj # UI routes (HTML) └── utils.clj # Route utilities ```