chore: auto-commit (21 archivos)
- app.md - backend/dist/assets/index-D_Kep7Fb.js - backend/dist/index.html - backend/handlers.go - backend/main.go - frontend/src/App.tsx - frontend/src/api.ts - frontend/src/components/CardChatPanel.tsx - frontend/src/components/LoginPage.tsx - frontend/src/types.ts - ... Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -9,7 +9,10 @@ FRONT_DIR="$ROOT/frontend"
|
||||
|
||||
PORT_BACK="${PORT_BACK:-8095}"
|
||||
PORT_FRONT="${PORT_FRONT:-5180}"
|
||||
DB_PATH="${DB_PATH:-./operations.db}"
|
||||
# Default DB lives at apps/kanban/operations.db. Force an absolute path so
|
||||
# the value survives the `cd $BACK_DIR` below — otherwise a relative
|
||||
# ./operations.db would land inside backend/.
|
||||
DB_PATH="${DB_PATH:-$ROOT/operations.db}"
|
||||
|
||||
cleanup() {
|
||||
echo ""
|
||||
@@ -22,9 +25,14 @@ cleanup() {
|
||||
trap cleanup INT TERM EXIT
|
||||
|
||||
# 1. Build backend si no existe o si los .go/.sql son mas nuevos que el binario
|
||||
if [[ ! -x "$BACK_DIR/kanban" ]] || [[ -n "$(find "$BACK_DIR" -maxdepth 3 \( -name '*.go' -o -name '*.sql' \) -newer "$BACK_DIR/kanban" 2>/dev/null)" ]]; then
|
||||
echo ">>> Building backend..."
|
||||
(cd "$BACK_DIR" && CGO_ENABLED=1 go build -tags fts5 -o kanban .)
|
||||
VERSION=$(awk -F': ' '/^version:/ {print $2; exit}' "$ROOT/app.md" 2>/dev/null || echo "dev")
|
||||
if [[ ! -x "$BACK_DIR/kanban" ]] \
|
||||
|| [[ -n "$(find "$BACK_DIR" -maxdepth 3 \( -name '*.go' -o -name '*.sql' \) -newer "$BACK_DIR/kanban" 2>/dev/null)" ]] \
|
||||
|| [[ "$ROOT/app.md" -nt "$BACK_DIR/kanban" ]]; then
|
||||
echo ">>> Building backend (version=$VERSION)..."
|
||||
(cd "$BACK_DIR" && CGO_ENABLED=1 go build -tags fts5 \
|
||||
-ldflags="-X main.Version=$VERSION" \
|
||||
-o kanban .)
|
||||
fi
|
||||
|
||||
# 2. Asegurar deps frontend
|
||||
|
||||
Reference in New Issue
Block a user