diff --git a/README.md b/README.md index d578626..c9444d4 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ mo --version # Show installed version - Safety first, if your Mac is mission-critical, wait for Mole to mature before full cleanups. - Preview the cleanup by running `mo clean --dry-run` and reviewing the generated list. -- Protect caches with `mo clean --whitelist`; defaults cover Playwright, HuggingFace, and Maven paths. +- Protect caches with `mo clean --whitelist`; defaults cover Playwright, HuggingFace, Maven, and Surge Mac paths. - Use `mo touchid` to approve sudo with Touch ID instead of typing your password. ## Quick Launchers diff --git a/bin/clean.sh b/bin/clean.sh index 3059fd1..4d2280b 100755 --- a/bin/clean.sh +++ b/bin/clean.sh @@ -34,6 +34,8 @@ declare -a DEFAULT_WHITELIST_PATTERNS=( "$HOME/.cache/huggingface*" "$HOME/.m2/repository/*" "$HOME/.ollama/models/*" + "$HOME/Library/Caches/com.nssurge.surge-mac/*" + "$HOME/Library/Application Support/com.nssurge.surge-mac/*" ) declare -a WHITELIST_PATTERNS=() WHITELIST_WARNINGS=() diff --git a/lib/whitelist_manager.sh b/lib/whitelist_manager.sh index 275cf24..15652b0 100755 --- a/lib/whitelist_manager.sh +++ b/lib/whitelist_manager.sh @@ -18,6 +18,8 @@ declare -a DEFAULT_WHITELIST_PATTERNS=( "$HOME/.cache/huggingface*" "$HOME/.m2/repository/*" "$HOME/.ollama/models/*" + "$HOME/Library/Caches/com.nssurge.surge-mac/*" + "$HOME/Library/Application Support/com.nssurge.surge-mac/*" ) # Save whitelist patterns to config @@ -28,7 +30,7 @@ save_whitelist_patterns() { cat > "$WHITELIST_CONFIG" << 'EOF' # Mole Whitelist - Protected paths won't be deleted -# Default protections: Playwright browsers, HuggingFace models, Maven repo, Ollama models +# Default protections: Playwright browsers, HuggingFace models, Maven repo, Ollama models, Surge Mac # Add one pattern per line to keep items safe. EOF @@ -118,6 +120,8 @@ Safari web browser cache|$HOME/Library/Caches/com.apple.Safari/*|browser_cache Chrome browser cache|$HOME/Library/Caches/Google/Chrome/*|browser_cache Firefox browser cache|$HOME/Library/Caches/Firefox/*|browser_cache Brave browser cache|$HOME/Library/Caches/BraveSoftware/Brave-Browser/*|browser_cache +Surge proxy cache|$HOME/Library/Caches/com.nssurge.surge-mac/*|network_tools +Surge configuration and data|$HOME/Library/Application Support/com.nssurge.surge-mac/*|network_tools Docker Desktop image cache|$HOME/Library/Containers/com.docker.docker/Data/*|container_cache Podman container cache|$HOME/.local/share/containers/cache/*|container_cache Font cache|$HOME/Library/Caches/com.apple.FontRegistry/*|system_cache