488a9a2140
Homebrew cask installers call sudo internally for each package that needs admin privileges. Without pre-authentication, macOS prompts for a password on every such package across a long brew bundle run. _ssr_sudo_keepalive_start: Calls 'sudo -v' once (prompts user if not already cached), then spawns a background loop that calls 'sudo -n true' every 60s to prevent the default 5-minute credential cache from expiring mid-run. _ssr_sudo_keepalive_stop: Kills the keepalive loop after brew bundle completes. If sudo is unavailable (non-admin user), a warning is shown and the run continues — individual cask installers that need sudo will prompt as before. Co-authored-by: Cursor <cursoragent@cursor.com>