38 lines
1.1 KiB
Bash
Executable File
38 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
# Display welcome message
|
|
echo "==================================================="
|
|
echo "Mycelium Society Website - Start Script"
|
|
echo "==================================================="
|
|
echo "This script will start the development server for the Mycelium Society website."
|
|
echo ""
|
|
|
|
# Check if pnpm is installed
|
|
if ! command -v pnpm &> /dev/null; then
|
|
echo "pnpm is not installed. Please run ./install.sh first."
|
|
exit 1
|
|
fi
|
|
|
|
# Check if node_modules exists
|
|
if [ ! -d "node_modules" ]; then
|
|
echo "Dependencies not installed. Running installation script..."
|
|
./install.sh
|
|
if [ $? -ne 0 ]; then
|
|
echo "Installation failed. Please check the error messages above."
|
|
exit 1
|
|
fi
|
|
fi
|
|
|
|
# Start development server
|
|
echo "Starting development server..."
|
|
echo "The website will be available at http://localhost:5173"
|
|
echo ""
|
|
echo "Press Ctrl+C to stop the server."
|
|
echo "==================================================="
|
|
|
|
pnpm run dev -- --host
|
|
|
|
# This script will not reach here unless the server is stopped
|
|
echo ""
|
|
echo "Development server stopped."
|