Files
VoiceStudio/package.json
T
Palash DebnathandClaude Fable 5 ea26893bfc fix(scripts): desktop-prod works from cmd/PowerShell via cross-platform launcher (#282) (#333)
`bun run desktop-prod` (and its :run/:upgrade/:pill/:run:pill variants)
invoked `bash scripts/desktop-prod.sh` directly. On Windows, cmd and
PowerShell have no `bash` on PATH unless Git Bash happens to be there,
so the documented from-source install path died with a cryptic spawn
failure before printing anything — the exact first step in issue #282's
repro.

Add scripts/desktop-prod.mjs, a tiny launcher (runs under bun or node):

- macOS/Linux: execs the bash script unchanged — zero behavior change.
- Windows: locates Git Bash via `where.exe bash`, well-known Git for
  Windows install paths, or derived from git.exe's location; explicitly
  skips C:\Windows\System32\bash.exe (the WSL launcher, which would run
  the script inside Linux and wipe/launch the wrong paths).
- No usable bash: prints an actionable error (install Git for Windows,
  use `bun run desktop`, or use the installer) instead of a spawn error.

All flags are forwarded untouched and the child's exit code is
propagated. scripts/desktop-prod.sh itself is unchanged, and
docs/install/windows.md now lists Git for Windows as a prerequisite
for from-source installs.

Refs #282

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-06-11 12:15:10 +05:30

42 lines
1.8 KiB
JSON

{
"name": "omnivoice-studio-monorepo",
"version": "1.0.0",
"license": "AGPL-3.0-only",
"private": true,
"packageManager": "bun@1.3.11",
"scripts": {
"setup:api": "uv sync && uv run python scripts/setup.py",
"dev:api": "uv run uvicorn main:app --app-dir backend --host 0.0.0.0 --port 3900 --reload --reload-dir backend",
"dev:frontend": "bun run --cwd frontend dev",
"dev:desktop": "bun run --cwd frontend desktop",
"wait:api": "wait-on -t 300000 http-get://localhost:3900/system/info",
"wait:frontend": "wait-on -t 120000 http://localhost:5173",
"predev": "kill-port 3900 3901 || true",
"dev": "bun run setup:api && concurrently -n api,fe -c green,cyan --kill-others-on-fail \"bun run dev:api\" \"bun run dev:frontend\"",
"predesktop": "kill-port 3900 3901 || true",
"desktop": "bun run setup:api && concurrently -n api,app -c green,magenta --kill-others-on-fail \"bun run dev:api\" \"bun run dev:desktop\"",
"desktop-prod": "bun scripts/desktop-prod.mjs",
"desktop-prod:run": "bun scripts/desktop-prod.mjs --skip-build",
"desktop-prod:upgrade": "bun scripts/desktop-prod.mjs --keep-data",
"desktop-prod:pill": "bun scripts/desktop-prod.mjs --pill",
"desktop-prod:run:pill": "bun scripts/desktop-prod.mjs --skip-build --pill",
"build": "turbo run build",
"start": "turbo run start",
"test:frontend": "node --test tests/frontend/*.test.mjs",
"smoke-test": "bash scripts/smoke-test.sh",
"smoke-test:quick": "bash scripts/smoke-test.sh --skip-build --skip-model",
"smoke-test:upgrade": "bash scripts/smoke-test.sh --keep-data --skip-build"
},
"workspaces": [
"frontend"
],
"devDependencies": {
"concurrently": "^9.2.1",
"kill-port-process": "^4.0.2",
"playwright": "^1.60.0",
"turbo": "^2.9.15",
"typescript": "^6.0.3",
"wait-on": "^9.0.10"
}
}