Skip to content

armgit / peel

Public Imported from GitHub
0

Uninstall Mac apps with every file they leave behind, and see why each belongs. Free up space, fine-tune macOS, and set up Terminal.

Keep Word's, PowerPoint's and Excel's unsaved work unselected

Țugui Dragoș56d992197a77
diff --git a/Packages/PeelCore/Sources/PeelCore/Leftovers/KeptOnlyHere.swift b/Packages/PeelCore/Sources/PeelCore/Leftovers/KeptOnlyHere.swift
index 1db1d01f..16ea0a90 100644
--- a/Packages/PeelCore/Sources/PeelCore/Leftovers/KeptOnlyHere.swift
+++ b/Packages/PeelCore/Sources/PeelCore/Leftovers/KeptOnlyHere.swift
@@ -139,6 +139,10 @@ enum KeptOnlyHere {
// Syncthing's "Syncthing Configuration": the folders it shares and the device's private key, the basis of its
// device ID.
("Library/Application Support/Syncthing", nil, .holdsWorkMadeWithTheApp),
+ // Microsoft's "Recover files in Office for Mac": the work AutoRecover kept and was never saved.
+ ("Library/Containers/com.Microsoft.Word", "Data/Library/Preferences/AutoRecovery", .holdsWorkMadeWithTheApp),
+ ("Library/Containers/com.Microsoft.Powerpoint", "Data/Library/Preferences/AutoRecovery", .holdsWorkMadeWithTheApp),
+ ("Library/Containers/com.microsoft.Excel", "Data/Library/Application Support/Microsoft", .holdsWorkMadeWithTheApp),
// Cultured Code's "Completely Uninstalling Things": deleting this group container deletes the to-dos.
("Library/Group Containers/JLMPQHK86H.com.culturedcode.ThingsMac", nil, .holdsWorkMadeWithTheApp),
// OBS Studio keeps its profiles and scene collections in `obs-studio/basic` in its configuration folder
diff --git a/Packages/PeelCore/Tests/PeelCoreTests/KeptOnlyHereTests.swift b/Packages/PeelCore/Tests/PeelCoreTests/KeptOnlyHereTests.swift
index b5c4243d..5c61813e 100644
--- a/Packages/PeelCore/Tests/PeelCoreTests/KeptOnlyHereTests.swift
+++ b/Packages/PeelCore/Tests/PeelCoreTests/KeptOnlyHereTests.swift
@@ -84,6 +84,11 @@ struct KeptOnlyHereTests {
("Library/Group Containers/group.com.criminalbird.typeface", .holdsWorkMadeWithTheApp),
("Library/Application Support/Syncthing", .holdsWorkMadeWithTheApp),
("Library/Application Support/Syncthing/key.pem", .holdsWorkMadeWithTheApp),
+ ("Library/Containers/com.Microsoft.Word", .holdsWorkMadeWithTheApp),
+ ("Library/Containers/com.microsoft.Word/Data/Library/Preferences/AutoRecovery/Report.docx",
+ .holdsWorkMadeWithTheApp),
+ ("Library/Containers/com.Microsoft.Powerpoint/Data/Library/Preferences/AutoRecovery", .holdsWorkMadeWithTheApp),
+ ("Library/Containers/com.microsoft.Excel/Data/Library/Application Support/Microsoft", .holdsWorkMadeWithTheApp),
("Library/Application Support/Tunnelblick/Configurations/work.tblk", .holdsVPNConnections),
("Library/Application Support/Viscosity", .holdsVPNConnections),
("Library/Application Support/Steam", .holdsWorkMadeWithTheApp),
@@ -147,6 +152,8 @@ struct KeptOnlyHereTests {
@Test func leavesWhatSitsBesideOrAroundThem() {
let free = [
"Library/Application Support", "Library/Group Containers", "Library", "Library/Caches/Signal",
+ "Library/Containers/com.microsoft.Word/Data/Library/Caches",
+ "Library/Containers/com.microsoft.Excel/Data/Library/Preferences",
"Library/Application Support/AutoBrew/Logs",
"Library/Application Support/nomic.ai", "Library/Application Support/Topaz Labs LLC",
"Library/Application Support/Topaz Labs LLC/Topaz Photo/models",