refactor: rename API and frontend projects to Vocero
Rename the project directories, Python distribution and import package, and npm package. Update launcher, Docker, tooling, tests, lockfiles, and documentation while preserving existing API contracts. Make AGENTS.md self-contained and remove external skill and workflow references.
This commit is contained in:
+12
-12
@@ -2,9 +2,9 @@
|
||||
set -euo pipefail
|
||||
|
||||
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
CLIENT_DIR="$ROOT_DIR/s2s-client"
|
||||
VENV_DIR="$CLIENT_DIR/.venv"
|
||||
FRONTEND_DIR="$ROOT_DIR/s2s-frontend"
|
||||
API_DIR="$ROOT_DIR/vocero-api"
|
||||
VENV_DIR="$API_DIR/.venv"
|
||||
FRONTEND_DIR="$ROOT_DIR/vocero-frontend"
|
||||
if [ -f "$ROOT_DIR/.env" ]; then
|
||||
set -a
|
||||
source "$ROOT_DIR/.env"
|
||||
@@ -28,7 +28,7 @@ for required_command in uv node npm setsid curl; do
|
||||
done
|
||||
|
||||
if ! node -e 'const [major, minor] = process.versions.node.split(".").map(Number); process.exit((major === 22 && minor >= 18) || major >= 24 ? 0 : 1)'; then
|
||||
echo "Error: s2s-frontend requires Node.js 22.18+ on the 22.x line, or Node.js 24+."
|
||||
echo "Error: vocero-frontend requires Node.js 22.18+ on the 22.x line, or Node.js 24+."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -46,19 +46,19 @@ if [ "$UI_PORT" = "$S2S_BACKEND_PORT" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -f "$CLIENT_DIR/pyproject.toml" ] || [ ! -f "$CLIENT_DIR/uv.lock" ]; then
|
||||
echo "Error: s2s-client/pyproject.toml and s2s-client/uv.lock are required."
|
||||
if [ ! -f "$API_DIR/pyproject.toml" ] || [ ! -f "$API_DIR/uv.lock" ]; then
|
||||
echo "Error: vocero-api/pyproject.toml and vocero-api/uv.lock are required."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# uv manages only the client environment; an existing root speech venv is separate.
|
||||
UV_PROJECT_ENVIRONMENT="$VENV_DIR" uv sync --project "$CLIENT_DIR" --locked
|
||||
# uv manages only the API environment; an existing root speech venv is separate.
|
||||
UV_PROJECT_ENVIRONMENT="$VENV_DIR" uv sync --project "$API_DIR" --locked
|
||||
|
||||
# Keep restarts offline when the installed frontend manifests have not changed.
|
||||
if [ ! -f "$FRONTEND_DIR/node_modules/vite/bin/vite.js" ] || \
|
||||
! cmp -s "$FRONTEND_DIR/package-lock.json" "$FRONTEND_DIR/node_modules/.s2s-package-lock.json" || \
|
||||
! cmp -s "$FRONTEND_DIR/package.json" "$FRONTEND_DIR/node_modules/.s2s-package.json"; then
|
||||
echo "Installing frontend dependencies from s2s-frontend/package-lock.json..."
|
||||
echo "Installing frontend dependencies from vocero-frontend/package-lock.json..."
|
||||
npm --prefix "$FRONTEND_DIR" ci --include=dev
|
||||
cp "$FRONTEND_DIR/package-lock.json" "$FRONTEND_DIR/node_modules/.s2s-package-lock.json"
|
||||
cp "$FRONTEND_DIR/package.json" "$FRONTEND_DIR/node_modules/.s2s-package.json"
|
||||
@@ -109,10 +109,10 @@ echo " Press Ctrl+C in this terminal to stop both servers."
|
||||
echo "----------------------------------------------------"
|
||||
|
||||
cd "$ROOT_DIR"
|
||||
setsid "$VENV_DIR/bin/python" -m uvicorn s2s_client.main:app \
|
||||
--app-dir "$CLIENT_DIR" \
|
||||
setsid "$VENV_DIR/bin/python" -m uvicorn vocero_api.main:app \
|
||||
--app-dir "$API_DIR" \
|
||||
--host 127.0.0.1 --port "$S2S_BACKEND_PORT" \
|
||||
--reload --reload-dir "$CLIENT_DIR" &
|
||||
--reload --reload-dir "$API_DIR" &
|
||||
backend_pid=$!
|
||||
child_pids+=("$backend_pid")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user