mirror of
https://github.com/tw93/Mole.git
synced 2026-02-04 17:24:45 +00:00
fix: improve cleanup code and fix Edge test isolation
- Refactor JetBrains Toolbox cleanup with _restore_whitelist helper - Add MOLE_EDGE_APP_PATHS env var for test isolation - Fix Edge old versions tests to avoid scanning system Edge installation
This commit is contained in:
@@ -110,10 +110,16 @@ clean_chrome_old_versions() {
|
||||
|
||||
# Remove old Microsoft Edge versions while keeping Current.
|
||||
clean_edge_old_versions() {
|
||||
local -a app_paths=(
|
||||
"/Applications/Microsoft Edge.app"
|
||||
"$HOME/Applications/Microsoft Edge.app"
|
||||
)
|
||||
# Allow override for testing
|
||||
local -a app_paths
|
||||
if [[ -n "${MOLE_EDGE_APP_PATHS:-}" ]]; then
|
||||
IFS=':' read -ra app_paths <<< "$MOLE_EDGE_APP_PATHS"
|
||||
else
|
||||
app_paths=(
|
||||
"/Applications/Microsoft Edge.app"
|
||||
"$HOME/Applications/Microsoft Edge.app"
|
||||
)
|
||||
fi
|
||||
|
||||
# Match the exact Edge process name to avoid false positives (e.g., Microsoft Teams)
|
||||
if pgrep -x "Microsoft Edge" > /dev/null 2>&1; then
|
||||
|
||||
Reference in New Issue
Block a user