mirror of
https://github.com/ChuckBuilds/LEDMatrix.git
synced 2026-10-11 01:26:37 +00:00
chore(scripts): delete unreferenced helper scripts
None of these is referenced by an installer, systemd unit, CI workflow, test, the web UI or src/: - utils/cleanup_venv.sh removes venv_web_v2, which nothing creates - utils/clear_python_cache.sh hardcodes ~/LEDMatrix and a .webassets-cache nothing uses - install/migrate_config.sh only copies the template, which the installer and ConfigManager already do - install/debug_install.sh, debug/debug_web_manual.py - diagnose_web_ui.sh and verify_web_ui.sh overlap diagnose_web_interface.sh, which the docs point to - fix_internet_connectivity.sh is iptables-only (stale on nftables) - diagnose_plugin_permissions.sh, dev/validate_python.py - download_nba_logos.py + README_NBA_LOGOS.md: logo_downloader fetches logos on demand - setup_plugin_repos.py linked into the production plugin-repos/ dir; the dev workflow is scripts/dev/dev_plugin_setup.sh, and MULTI_ROOT_WORKSPACE_SETUP.md now uses it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -19,9 +19,6 @@ This directory contains scripts for installing and configuring the LEDMatrix sys
|
||||
(the user who runs the script, i.e. the one you installed LEDMatrix as;
|
||||
there is no `ledmatrix` system user) the passwordless `nmcli` and related
|
||||
WiFi permissions the web interface needs
|
||||
- **`migrate_config.sh`** - Migrates configuration files to new formats (if needed)
|
||||
- **`debug_install.sh`** - Diagnostic helper used when an install
|
||||
fails; collects environment info and recent logs
|
||||
|
||||
## Usage
|
||||
|
||||
|
||||
@@ -1,85 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Quick diagnostic script to check why first_time_install.sh is failing
|
||||
# Run this on the Pi: bash debug_install.sh
|
||||
|
||||
echo "=== Diagnostic Script for Installation Failure ==="
|
||||
echo ""
|
||||
|
||||
echo "1. Checking if running as root:"
|
||||
if [ "$EUID" -eq 0 ]; then
|
||||
echo " ✓ Running as root (EUID=$EUID)"
|
||||
else
|
||||
echo " ✗ NOT running as root (EUID=$EUID, user=$(whoami))"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
echo "2. Checking if first_time_install.sh exists:"
|
||||
if [ -f "./first_time_install.sh" ]; then
|
||||
echo " ✓ Found ./first_time_install.sh"
|
||||
echo " Checking if executable:"
|
||||
if [ -x "./first_time_install.sh" ]; then
|
||||
echo " ✓ Is executable"
|
||||
else
|
||||
echo " ✗ NOT executable (fix with: chmod +x first_time_install.sh)"
|
||||
fi
|
||||
else
|
||||
echo " ✗ NOT found in current directory"
|
||||
echo " Current directory: $(pwd)"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
echo "3. Testing argument passing with -y flag:"
|
||||
echo " Running: bash ./first_time_install.sh -y --help 2>&1 | head -20"
|
||||
if [ -f "./first_time_install.sh" ]; then
|
||||
bash ./first_time_install.sh -y --help 2>&1 | head -20 || echo " ✗ Script failed or not found"
|
||||
else
|
||||
echo " ✗ first_time_install.sh not found"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
echo "4. Checking environment variable:"
|
||||
echo " LEDMATRIX_ASSUME_YES=${LEDMATRIX_ASSUME_YES:-not set}"
|
||||
echo " Testing with env: env LEDMATRIX_ASSUME_YES=1 bash -c 'echo ASSUME_YES would be set'"
|
||||
env LEDMATRIX_ASSUME_YES=1 bash -c 'echo " ASSUME_YES would be: ${LEDMATRIX_ASSUME_YES:-not set}"'
|
||||
echo ""
|
||||
|
||||
echo "5. Testing sudo with arguments:"
|
||||
echo " Command: sudo -E env LEDMATRIX_ASSUME_YES=1 bash ./first_time_install.sh -y --help 2>&1 | head -20"
|
||||
if [ -f "./first_time_install.sh" ]; then
|
||||
sudo -E env LEDMATRIX_ASSUME_YES=1 bash ./first_time_install.sh -y --help 2>&1 | head -20 || echo " ✗ Sudo command failed"
|
||||
else
|
||||
echo " ✗ first_time_install.sh not found"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
echo "6. Checking /tmp permissions:"
|
||||
echo " /tmp is writable: $([ -w /tmp ] && echo 'YES' || echo 'NO')"
|
||||
echo " /tmp permissions: $(stat -c '%a' /tmp 2>/dev/null || echo 'unknown')"
|
||||
echo " TMPDIR: ${TMPDIR:-not set}"
|
||||
echo ""
|
||||
|
||||
echo "7. Checking stdin/TTY:"
|
||||
if [ -t 0 ]; then
|
||||
echo " ✓ stdin is a TTY (interactive)"
|
||||
else
|
||||
echo " ✗ stdin is NOT a TTY (non-interactive/pipe)"
|
||||
echo " This is expected when running via curl | bash"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
echo "8. Latest installation log:"
|
||||
# Determine project root directory (parent of scripts/install/)
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
PROJECT_ROOT_DIR="$(cd "$SCRIPT_DIR/../.." && pwd)"
|
||||
LOG_DIR="$PROJECT_ROOT_DIR/logs"
|
||||
LOG_FILE=$(ls -t "$LOG_DIR"/first_time_install_*.log 2>/dev/null | head -1)
|
||||
if [ -n "$LOG_FILE" ]; then
|
||||
echo " Found: $LOG_FILE"
|
||||
echo " Last 30 lines:"
|
||||
tail -30 "$LOG_FILE" | sed 's/^/ /'
|
||||
else
|
||||
echo " No log files found in $LOG_DIR/"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
echo "=== Diagnostic Complete ==="
|
||||
@@ -1,43 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# LED Matrix Configuration Migration Script
|
||||
# This script helps migrate existing config.json to the new template-based system
|
||||
|
||||
set -e
|
||||
|
||||
echo "=========================================="
|
||||
echo "LED Matrix Configuration Migration Script"
|
||||
echo "=========================================="
|
||||
echo ""
|
||||
|
||||
# Check if we're in the right directory
|
||||
if [ ! -f "config/config.template.json" ]; then
|
||||
echo "Error: config/config.template.json not found."
|
||||
echo "Please run this script from the LEDMatrix project root directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check if config.json exists
|
||||
if [ ! -f "config/config.json" ]; then
|
||||
echo "No existing config.json found. Creating from template..."
|
||||
cp config/config.template.json config/config.json
|
||||
echo "✓ Created config/config.json from template"
|
||||
echo ""
|
||||
echo "You can now edit config/config.json with your preferences."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "Existing config.json found. The system will automatically handle migration."
|
||||
echo ""
|
||||
echo "What this means:"
|
||||
echo "- Your current config.json will be preserved"
|
||||
echo "- New configuration options will be automatically added with default values"
|
||||
echo "- A backup will be created before any changes"
|
||||
echo "- The system handles this automatically when it starts"
|
||||
echo ""
|
||||
echo "No manual migration is needed. The ConfigManager will handle everything automatically."
|
||||
echo ""
|
||||
echo "To see the latest configuration options, you can reference:"
|
||||
echo " config/config.template.json"
|
||||
echo ""
|
||||
echo "Migration complete!"
|
||||
Reference in New Issue
Block a user