-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·47 lines (40 loc) · 1.09 KB
/
setup.sh
File metadata and controls
executable file
·47 lines (40 loc) · 1.09 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
#!/bin/bash
echo "Setup..."
# 1. Check for Python 3
if ! command -v python3 &> /dev/null
then
echo "❌ Python 3 could not be found. Please install Python 3."
exit 1
fi
echo "Python 3 found: $(python3 --version)"
# 2. Create Virtual Environment
echo "Creating virtual environment (.venv)..."
python3 -m venv .venv
# 3. Activate Virtual Environment
source .venv/bin/activate
# 4. Install Dependencies
echo "Installing dependencies"
pip install --upgrade pip
pip install -r requirements.txt
# 5. Create .env
if [ ! -f .env ]; then
echo "⚠️ Please edit .env and add your Groq API Token."
else
echo ".env file already exists."
fi
echo ""
echo "==========================================="
echo "Setup Complete!"
echo "==========================================="
echo ""
echo "Next Steps:"
echo " 1. Edit .env with your Groq API Token:"
echo " nano .env"
echo ""
echo " 2. Run the application:"
echo " source .venv/bin/activate && python src/main.py"
echo ""
echo " 3. Open in browser:"
echo " http://localhost:7860"
echo ""
echo "==========================================="