- Replace `find | head -n 1` with `find -print -quit` to avoid SIGPIPE
failures under `set -eo pipefail`
- Add root privilege check at script start with clear error message
- Add logname fallback to SUDO_USER/USER for non-login shell environments
- Use absolute path for cd into DaVinci_Resolve directory
- Replace unquoted glob mv commands with a for loop that checks file
existence before moving, avoiding false errors and masking real ones
https://claude.ai/code/session_01LLCGJrKAHAS1HA26Coq1VM