fix: tab highlight reactivity, cleanup docs and build scripts
- Fix tab highlight not updating visually — switch from class={tabClass()}
to Svelte's class:active directive for proper reactive class binding
- Rewrite README.md with full project structure, architecture, build guide
- Rewrite build.sh to build both GUI and server, output to build/
- Add scripts/build.sh for granular builds (gui/server/all)
- Add build/, frontend-dist/, and test vault dirs to .gitignore
- Remove stale binaries from project root
- Update AGENTS.md session summary
This commit is contained in:
Executable
+44
@@ -0,0 +1,44 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
# Individual build scripts
|
||||
|
||||
build_gui() {
|
||||
echo "==> Building GUI binary..."
|
||||
|
||||
# Build frontend
|
||||
cd frontend && npm run build && cd ..
|
||||
|
||||
# Copy frontend dist to Wails embed directory
|
||||
cp -r frontend/dist/* cmd/verstak-gui/frontend-dist/
|
||||
|
||||
# Build Go binary with Wails v2
|
||||
# Tags: webkit2_41 required for WebKitGTK 2.41+, desktop/production for Wails
|
||||
go build -tags "webkit2_41 desktop production" -ldflags="-s -w" -o build/verstak-gui-linux-amd64 ./cmd/verstak-gui/
|
||||
|
||||
echo "==> GUI binary: build/verstak-gui-linux-amd64"
|
||||
}
|
||||
|
||||
build_server() {
|
||||
echo "==> Building server binary..."
|
||||
go build -ldflags="-s -w" -o build/verstak-server-linux-amd64 ./cmd/verstak-server/
|
||||
echo "==> Server binary: build/verstak-server-linux-amd64"
|
||||
}
|
||||
|
||||
build_all() {
|
||||
mkdir -p build
|
||||
build_gui
|
||||
build_server
|
||||
echo "==> All binaries built."
|
||||
ls -lh build/
|
||||
}
|
||||
|
||||
case "${1:-all}" in
|
||||
gui) build_gui ;;
|
||||
server) build_server ;;
|
||||
all) build_all ;;
|
||||
*)
|
||||
echo "Usage: $0 [gui|server|all]"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
Reference in New Issue
Block a user