- New 'instant' mode polls every 0.5 seconds (vs 3s for regular mode)
- Made instant mode the default for the systemd service
- Added youtube-music-wrapper.sh to block launch when focus apps running
- YouTube Music killed within 0.5 seconds of opening
- Added 'youtube-music' and 'YouTube Music' patterns to detect Electron app
- Added explicit killing of youtube-music process
- Use SIGKILL (-9) to ensure apps are actually terminated
- Fixed log function to not fail on permission errors
Prevents multitasking between focus work and music streaming.
When focus apps (VS Code, Steam, Godot, etc.) are detected running
alongside music services (YouTube Music, Spotify, etc.), the music
is automatically stopped.
Features:
- Monitors for focus applications (IDEs, games, creative software)
- Detects music streaming via browser tabs and native apps
- Closes music windows/processes when conflict detected
- Desktop notifications when music is stopped
- Status command to check current state
- Systemd service for background monitoring
- Add RefuseManualStop=true to prevent systemctl stop
- Add RestartForceExitStatus to restart even on SIGTERM/SIGKILL
- Add watchdog timer that checks monitor every 60 seconds
- Watchdog also restarts the main timer if stopped
- Tested: manual stop refused, pkill auto-restarts, timer tampering detected
- Remove 'disable' option from setup_midnight_shutdown.sh
- Add shutdown-timer-monitor.sh that watches the timer every 30s
- Re-enables timer automatically if someone tries to disable it
- Monitor service installed alongside the timer
- Makes it significantly harder to bypass the shutdown schedule
- Similar pattern to hosts-file-monitor.service
- Track custom blocked entries in /etc/hosts.custom-entries.state
- Block installation if any previously blocked entries are removed
- No bypass option - manual chattr removal required for changes
- Protects against impulsive unblocking of sites
- State file is also protected with chattr +i
This is the original all-in-one script that was later split into:
- raspberry_pi_flash_sd.sh (SD card flashing)
- raspberry_pi_nextcloud.sh (Nextcloud installation)
Kept for reference and as an alternative single-script deployment option.
- raspberry_pi_flash_sd.sh: Flash RPi OS to SD card (local/remote)
- Auto-discovers SD cards on local or remote systems
- Configures headless SSH access with auto-generated passwords
- Supports flashing via remote laptop with SD card reader
- raspberry_pi_nextcloud.sh: Install and configure Nextcloud
- Automated installation of Nextcloud with Apache, MariaDB, Redis
- DuckDNS + Let's Encrypt for publicly trusted HTTPS
- Security hardening: HSTS, cron jobs, default phone region
- Auto-generated admin credentials stored in config file
- fix command for security warnings
- setup-ssl-remote for Let's Encrypt via DuckDNS
Includes shellcheck compliance with appropriate directives.
- Add fix_systemctl.sh to repair corrupted media-organizer.service
- Fix setup_media_organizer.sh to use SUDO_USER instead of whoami
when running with sudo (prevents User/Group being set to root)
The service was failing due to:
1. Corrupted ExecStart path (line break in the middle)
2. Wrong script path (missing 'utils/' directory)
3. User/Group set to root instead of actual user
- Fix startup_monitor check to verify timer instead of service
- Fix pacman hooks filename check (10-unlock-etc-hosts.hook, 90-relock-etc-hosts.hook)
- Add re-verification after fixes to update status correctly
- Set immutable attribute before bind mount in pacman-post-relock-hosts.sh
- Add new check_and_enable_services.sh script for verifying all digital wellbeing services
- Auto-fix with shfmt on staged files
- Run shellcheck validation directly instead of full shell_check.sh
- Avoids shfmt -d validation after auto-formatting (prevents .orig file loop)
- Ensures consistent formatting without blocking commits
- Replace 'A && B || C' patterns with proper if-then-else statements (SC2015)
- Add check_for_virtualbox function to invoke prompt_for_virtualbox_challenge (SC2317)
- Fix install_launcher function to escape variable in heredoc (SC2119/SC2120)
- Apply shfmt formatting to ensure consistent style
Fixes 7 SC2015 violations, 1 SC2317 violation, and 1 SC2119/SC2120 pair.
All 79 shell files now pass shellcheck without errors.