- src/db/seed.ts: comprehensive seed data with idempotent upserts - 5 users (system, gjermund, operator, technician, analyst) - 5 queues (Support Desk, Operations, IT Infrastructure, Facilities, Field Ops) - 1 lifecycle (Demo service lifecycle with new→open→in_progress→resolved→closed) - 5 custom fields (impact, location, channel, urgency, outcome) with short keys - 10 realistic support tickets with varied statuses, custom fields, and history - 3 scrips (OnCreate email, OnResolve custom field, customer notification) - 2 templates (auto-response, resolve notification) - --reset flag to truncate all data before seeding - scripts/smoke-test.ts: API smoke tests - scripts/watch-frontend.sh: frontend dev helper Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
16 lines
516 B
Bash
16 lines
516 B
Bash
#!/usr/bin/env bash
|
|
# Watch for source changes and auto-rebuild + restart Tessera frontend
|
|
DIR="/home/gjermund/projects/tessera/web/src"
|
|
LAST_BUILD=0
|
|
|
|
echo "Watching $DIR for changes..."
|
|
|
|
inotifywait -m -r -e modify,create,delete "$DIR" --format '%w%f' 2>/dev/null | while read FILE; do
|
|
NOW=$(date +%s)
|
|
if [ $((NOW - LAST_BUILD)) -gt 3 ]; then
|
|
echo "[$(date +%H:%M:%S)] Change detected, rebuilding..."
|
|
cd /home/gjermund/projects/tessera/web && npx next build 2>&1 | tail -1
|
|
LAST_BUILD=$NOW
|
|
fi
|
|
done
|