From 2fa5e2d9af410fd1738f99717c281e613b03c217 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Sun, 3 Aug 2025 18:59:23 -0400 Subject: [PATCH] Removed running from usb check for install to disk option. --- usr/local/bin/game_launcher.py | 40 ++-------------------------------- 1 file changed, 2 insertions(+), 38 deletions(-) diff --git a/usr/local/bin/game_launcher.py b/usr/local/bin/game_launcher.py index e9e759a..9a02baf 100755 --- a/usr/local/bin/game_launcher.py +++ b/usr/local/bin/game_launcher.py @@ -925,44 +925,8 @@ if __name__ == "__main__": # Add system section menu.add_section("System") - # Add installer only on x86_64 and when running from USB - import platform - import subprocess - import re - - def is_running_from_usb(): - try: - # Get the root device - result = subprocess.run(['findmnt', '-n', '-o', 'SOURCE', '/'], - capture_output=True, text=True) - if result.returncode != 0: - return False - - root_device = result.stdout.strip() - - # Extract device name without partition number - device_match = re.match(r'^(/dev/(?:sd[a-z]|nvme[0-9]n[0-9]|mmcblk[0-9]))', root_device) - if not device_match: - return False - - device_name = device_match.group(1) - - # Check if device is removable (USB/SD card) - try: - with open(f'/sys/block/{device_name.split("/")[-1]}/removable', 'r') as f: - removable = f.read().strip() - return removable == '1' - except: - # Fallback: check for STORMUX label (live USB indicator) - result = subprocess.run(['lsblk', '-no', 'NAME,LABEL'], - capture_output=True, text=True) - if result.returncode == 0: - return 'STORMUX' in result.stdout.upper() - return False - except: - return False - - if platform.machine() == "x86_64" and is_running_from_usb(): + # Add installer only on x86_64 + if platform.machine() == "x86_64": menu.add_item("System", "Install System to Hard Drive", "GAME='Install to Disk' /home/stormux/.clirc") menu.add_item("System", "Internet Configuration", "GAME=\"Network Configuration\" /home/stormux/.clirc")