feat: replace air with templ hot reload
Some checks failed
Build Docker Image / Build-Docker-Image (push) Failing after 4m3s

This commit is contained in:
2025-05-06 20:00:57 +02:00
parent f085ed378e
commit 605c64ef92
3 changed files with 7 additions and 17 deletions

View File

@@ -1,15 +0,0 @@
root = "."
tmp_dir = "tmp"
[build]
bin = "./tmp/main"
cmd = "templ generate && go build -o ./tmp/main ."
exclude_dir = ["static", "migrations", "node_modules", "tmp"]
exclude_regex = ["_test.go", "_templ.go"]
include_ext = ["go", "templ"]
send_interrupt = true
kill_delay = "5s"
stop_on_error = true
[misc]
clean_on_exit = true

View File

@@ -4,9 +4,8 @@ import (
"spend-sparrow/log" "spend-sparrow/log"
"spend-sparrow/types" "spend-sparrow/types"
"github.com/jmoiron/sqlx"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/jmoiron/sqlx"
) )
type Account interface { type Account interface {

6
dev.sh Executable file
View File

@@ -0,0 +1,6 @@
templ generate --watch --proxy="http://localhost:8080" --cmd="go run ." &
npm run watch &
read -n1 -s
kill $(jobs -p)