From fcb152c1c80cec303640ed203c94c995971d46ea Mon Sep 17 00:00:00 2001 From: samantha Date: Fri, 27 Mar 2026 10:41:18 +0000 Subject: [PATCH] Add Getting Started --- Getting-Started.md | 48 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 Getting-Started.md diff --git a/Getting-Started.md b/Getting-Started.md new file mode 100644 index 0000000..bdf98dc --- /dev/null +++ b/Getting-Started.md @@ -0,0 +1,48 @@ +# Getting Started + +## Prerequisites + +- Go 1.21+ +- GCC (required for SQLite CGO bindings) + - Ubuntu/Debian: `sudo apt install gcc` + - macOS: comes with Xcode Command Line Tools (`xcode-select --install`) + +## Clone and Run + +```bash +git clone git@git.samantha42.xyz:samantha/Portfolio-Engine.git +cd Portfolio-Engine +go mod download +go run main.go +``` + +## Build + +```bash +chmod +x build.sh +./build.sh +./Portifolio +``` + +## Startup Output + +``` +Connected to SQLite database +Tables ready +Server running on :8080 + +Shell ready. Type 'help' for commands. +> +``` + +The HTTP server and the interactive shell run concurrently. The API is live while you type shell commands. + +The SQLite database (`app.db`) is created automatically on first run in the project root. Foreign key enforcement is enabled. + +## Verify It's Running + +```bash +curl http://localhost:8080/health +``` + +A `200 OK` with a JSON body confirms the server is up and the database is reachable. A `503` with `"status": "degraded"` means the database is unreachable. \ No newline at end of file