-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmythtech_installer.sh
More file actions
42 lines (35 loc) · 1.1 KB
/
mythtech_installer.sh
File metadata and controls
42 lines (35 loc) · 1.1 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
#!/bin/bash
# MythTech Control Center Installer
echo "[MythTech] Installing MythTech Control Center launcher..."
# Paths
APP_DIR="$HOME/Downloads/MythTechAppDir"
BIN_PATH="$APP_DIR/usr/bin"
DESKTOP_FILE="$HOME/.local/share/applications/mythtech-control.desktop"
LAUNCH_SCRIPT="$BIN_PATH/MythTechControl.sh"
# 1. Create launch script
mkdir -p "$BIN_PATH"
cat > "$LAUNCH_SCRIPT" <<EOF
#!/bin/bash
echo "[MythTech] Starting Control Center..."
/usr/bin/python3 $BIN_PATH/MythTechControlCenter.py
echo "[MythTech] GUI closed. Shell still active."
exec bash
EOF
# 2. Make it executable
chmod +x "$LAUNCH_SCRIPT"
# 3. Create .desktop launcher
mkdir -p "$(dirname "$DESKTOP_FILE")"
cat > "$DESKTOP_FILE" <<EOF
[Desktop Entry]
Name=MythTech Control Center
Comment=Launch the MythTech Codex GUI
Exec=$LAUNCH_SCRIPT
Icon=utilities-terminal
Terminal=true
Type=Application
Categories=Development;
EOF
# 4. Set trusted & executable
chmod +x "$DESKTOP_FILE"
gio set "$DESKTOP_FILE" metadata::trusted true 2>/dev/null || true
echo "[MythTech] Installation complete. Search for 'MythTech Control Center' in your Applications menu."