| name | relaunch |
| description | Kill the running Baalda desktop (Tauri) dev instance AND the backend server, then launch fresh instances of both. Use when the user says "relaunch", "restart the app", "kill and relaunch", or wants a clean restart after code/config changes. |
Relaunch Skill Guide
Kills the current desktop (Tauri) dev process tree and the backend server, then
starts fresh instances of both. Postgres (Docker) is left running — restarting
the server process does not touch the DB, so no re-seed is needed.
Project: /Users/macbook/Documents/Baalda/app
- Desktop launch:
npm run dev:desktop (= npm run tauri dev -w desktop; Vite on :1420) from the app root.
- Server launch:
npm run dev from app/apps/server/ (tsx watch; HTTP :3010, Hocuspocus WS :3011, GET /health).
Steps
1. Kill the running instances
Kill both the desktop dev chain (dev:desktop → tauri dev → vite →
target/debug/desktop) and the backend server (tsx src/index.ts).
pkill -f "target/debug/desktop"
pkill -f "node_modules/.bin/tauri"
pkill -f "node_modules/.bin/vite"
pkill -f "dev:desktop"
pkill -f "tauri dev"
pkill -f "tsx.*src/index.ts"
pkill -f "apps/server"
sleep 1
pgrep -fl "tauri dev|node_modules/.bin/vite|target/debug/desktop|tsx.*src/index.ts" || echo "all stopped"
If pgrep still lists survivors, kill -9 them by PID.
2. Make sure Postgres is up
The server needs Postgres (Docker, host port 5439). It usually stays up across
restarts — only start it if it's missing.
docker ps --filter "publish=5439" --format "{{.Names}} {{.Status}}" || true
Do not run npm run migrate unless migrations changed, and never run
npm test in apps/server (it wipes the dev DB / users/orgs/vaults).
3. Launch the backend server
Run in the background from the server dir. Use the Bash tool with
run_in_background: true.
cd /Users/macbook/Documents/Baalda/app/apps/server && npm run dev
4. Launch the desktop
Run in the background from the app root. Use the Bash tool with
run_in_background: true.
cd /Users/macbook/Documents/Baalda/app && npm run dev:desktop
5. Confirm both came up
- Server (wait ~3–5s):
curl -s http://localhost:3010/health returns OK, and
the task output shows the HTTP :3010 / Hocuspocus WS listeners started.
- Desktop (wait ~15–20s; cargo may recompile): tail the background task output.
Success looks like:
VITE v7.x ready ...
Running `target/debug/desktop`
If tauri.conf.json or Rust changed, expect a Compiling desktop / Rebuilding application... step before Running target/debug/desktop.
Notes
- If a process was launched from a Claude background shell in this session, kill that
background task too (via its task id) so its output stream closes cleanly.
- Restarting the server process is safe — it does not re-seed or wipe anything.
Only
npm test in apps/server wipes the DB.
- A
tauri.conf.json edit auto-triggers a rebuild in a running tauri dev, so a
full relaunch is only needed when the watcher isn't running or you want a clean slate.