Files
integral-shop/start-frontend.sh

22 lines
581 B
Bash
Raw Normal View History

#!/bin/bash
# ============================================
# 启动 Frontend Dev Server (Vue 2 + Element UI)
# 端口: 9527 API: 见 .env.development
# ============================================
set -e
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
cd "$SCRIPT_DIR/backend-adminend"
echo "📦 Working dir: $(pwd)"
# 如果 node_modules 不存在则先安装
if [ ! -f "node_modules/.bin/vue-cli-service" ]; then
echo "📥 Installing dependencies ..."
npm install --legacy-peer-deps
fi
echo "🚀 Starting Vue dev server on http://localhost:9527 ..."
echo ""
npm run dev