-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstart.sh
More file actions
65 lines (55 loc) · 1.61 KB
/
start.sh
File metadata and controls
65 lines (55 loc) · 1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
#!/bin/bash
# Voice Assistant Quick Start Script
# This script will help you set up and run the voice assistant
echo "Voice Assistant Setup Script"
echo "================================"
echo ""
# Check Python installation
echo "Checking Python installation..."
if ! command -v python3 &> /dev/null; then
echo "Error: Python 3 is not installed. Please install Python 3.8 or higher."
exit 1
fi
PYTHON_VERSION=$(python3 --version)
echo "Found: $PYTHON_VERSION"
echo ""
# Create virtual environment
echo "Creating virtual environment..."
if [ ! -d "venv" ]; then
python3 -m venv venv
echo "Virtual environment created"
else
echo "Virtual environment already exists"
fi
echo ""
# Activate virtual environment
echo "Activating virtual environment..."
source venv/bin/activate
echo "Virtual environment activated"
echo ""
# Install dependencies
echo "Installing dependencies..."
pip install -r requirements.txt
echo "Dependencies installed"
echo ""
# Create .env file if it doesn't exist
if [ ! -f ".env" ]; then
echo "Creating .env file..."
cp .env.example .env
echo "Warning: Please edit .env and add your Google Gemini API key"
echo " Get your key from: https://aistudio.google.com/apikey"
echo ""
read -p "Press Enter to continue after adding your API key..."
fi
# Create necessary directories
echo "Creating necessary directories..."
mkdir -p static/css static/js templates logs
echo "Directories created"
echo ""
# Run the application
echo "Starting the voice assistant..."
echo " Access it at: http://localhost:8080"
echo ""
echo "Press Ctrl+C to stop the server"
echo ""
python3 -m src.app