Repository navigation
Expand file tree
/
Copy pathinstall.sh
More file actions
85 lines (73 loc) · 3.5 KB
/
Copy pathinstall.sh
File metadata and controls
85 lines (73 loc) · 3.5 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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
#!/bin/bash
#================================================================================
# Student Performance Analytics Dashboard - Installer
# GitHub: https://github.com/issu321/Data-Visualize-Py.git
# Kali Linux / Debian / Ubuntu Compatible
#================================================================================
set -e
RED='\033[0;31m'
GREEN='\033[0;32m'
CYAN='\033[0;36m'
YELLOW='\033[1;33m'
MAGENTA='\033[0;35m'
NC='\033[0m'
echo -e "${MAGENTA}"
echo "╔══════════════════════════════════════════════════════════════╗"
echo "║ STUDENT PERFORMANCE ANALYTICS DASHBOARD ║"
echo "║ GitHub: issu321 ║"
echo "╚══════════════════════════════════════════════════════════════╝"
echo -e "${NC}"
# Detect Python
PYTHON_CMD="python3"
if command -v python3 &> /dev/null; then
PY_VERSION=$(python3 --version 2>&1 | awk '{print $2}')
echo -e "${GREEN}[+] Python detected: $PY_VERSION${NC}"
else
echo -e "${RED}[!] Python not found!${NC}"
exit 1
fi
# Update system
echo -e "${CYAN}[*] Updating package list...${NC}"
sudo apt-get update -qq
# Install system dependencies
echo -e "${CYAN}[*] Installing system dependencies...${NC}"
sudo apt-get install -y -qq \
python3-pip \
python3-dev \
python3-venv \
build-essential \
libfreetype6-dev \
libpng-dev \
libjpeg-dev \
pkg-config \
git \
curl \
wget \
python3-tk
# Upgrade pip
echo -e "${CYAN}[*] Upgrading pip...${NC}"
$PYTHON_CMD -m pip install --upgrade pip setuptools wheel
# Install Python packages
echo -e "${CYAN}[*] Installing Python packages...${NC}"
$PYTHON_CMD -m pip install -r requirements.txt
# Create directories
echo -e "${CYAN}[*] Setting up directories...${NC}"
mkdir -p output
# Make scripts executable
echo -e "${CYAN}[*] Setting permissions...${NC}"
chmod +x run.sh
chmod +x install.sh
# Verify
echo -e "${CYAN}[*] Verifying installation...${NC}"
$PYTHON_CMD -c "import numpy; import pandas; import matplotlib; import openpyxl; print('All OK')" 2>/dev/null && \
echo -e "${GREEN}[+] All packages installed successfully${NC}" || echo -e "${RED}[!] Some packages failed${NC}"
echo -e "${GREEN}"
echo "╔══════════════════════════════════════════════════════════════╗"
echo "║ INSTALLATION COMPLETE! ║"
echo "╠══════════════════════════════════════════════════════════════╣"
echo "║ GitHub: https://github.com/issu321/Data-Visualize-Py.git"
echo "╠══════════════════════════════════════════════════════════════╣"
echo "║ Run: ./run.sh ║"
echo "║ Or: python3 src/student_analytics.py ║"
echo "╚══════════════════════════════════════════════════════════════╝"
echo -e "${NC}"