Add hot-reload support with air for Go backend

- Add .air.toml configuration for Go hot-reloading
- Add 'dev' target to run both frontend and backend together
- Update dev-backend to use air instead of go run
- Install air with: go install github.com/air-verse/air@latest
This commit is contained in:
Christoph Haas 2026-03-23 21:40:40 +01:00
parent 44dea14885
commit ad159b2549
2 changed files with 26 additions and 4 deletions

18
backend/.air.toml Normal file
View file

@ -0,0 +1,18 @@
# .air.toml - Air configuration for hot-reloading Go backend
# Install air: go install github.com/air-verse/air@latest
[root]
temp_dir = "tmp"
watch_dirs = ["."]
ignore_dirs = ["tmp", "vendor", "cmd/server/embed"]
[build]
bin = "./tmp/imc-vibe"
cmd = "go build -o ./tmp/imc-vibe ./cmd/server"
stop_on_error = true
[log]
main_only = true
[misc]
clean_on_exit = true