Skip to content

Commit ac71139

Browse files
committed
feat(clean): add new cache targets from Mac scan
Add 20+ new clean items identified by deep-scanning the local Mac: Dev tools (lib/clean/dev.sh): - Swift PM library cache (org.swift.swiftpm, 130M) - GitHub Copilot cache (72M) - VS Code ripgrep binary cache - Prisma ORM engine cache (23M) - OpenCode AI tool cache - Qoder IDE (VS Code fork): CachedData, extensions, GPU/Dawn caches, logs (507M) - Claude Desktop: sentry cache, pending-uploads GUI apps (lib/clean/app_caches.sh): - Codex (OpenAI Electron app): Cache, Code Cache, GPU/Dawn caches, logs - NetNewsWire container cache - MindNode container cache - Kaku user cache - WeType input method: image cache and dict update cache - mihomo-party proxy tool (Electron): full cache set + logs (48M logs) - Stash proxy tool cache - Raycast: urlcache + fsCachedData only (Clipboard folder excluded) Apple system (lib/clean/user.sh): - macOS Help system cache (com.apple.helpd, 32M) - Maps geo tile cache (GeoServices, 63M) - Memoji picker container cache (41M) - Music album art container cache (8M) - CoreDevice service container cache (19M) - Apple Intelligence extension container cache - Apple Media Services temp files
1 parent c279952 commit ac71139

3 files changed

Lines changed: 51 additions & 1 deletion

File tree

lib/clean/app_caches.sh

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ clean_communication_apps() {
104104
safe_clean ~/Library/Caches/us.zoom.xos/* "Zoom cache"
105105
safe_clean ~/Library/Caches/com.tencent.xinWeChat/* "WeChat cache"
106106
safe_clean ~/Library/Caches/ru.keepcoder.Telegram/* "Telegram cache"
107+
107108
safe_clean ~/Library/Caches/com.microsoft.teams2/* "Microsoft Teams cache"
108109
safe_clean ~/Library/Caches/net.whatsapp.WhatsApp/* "WhatsApp cache"
109110
safe_clean ~/Library/Caches/com.skype.skype/* "Skype cache"
@@ -129,6 +130,13 @@ clean_ai_apps() {
129130
safe_clean ~/Library/Caches/com.openai.chat/* "ChatGPT cache"
130131
safe_clean ~/Library/Caches/com.anthropic.claudefordesktop/* "Claude desktop cache"
131132
safe_clean ~/Library/Logs/Claude/* "Claude logs"
133+
safe_clean ~/Library/Logs/com.openai.codex/* "Codex CLI logs"
134+
# Codex (OpenAI, Electron)
135+
safe_clean ~/Library/Application\ Support/Codex/Cache/* "Codex cache"
136+
safe_clean ~/Library/Application\ Support/Codex/Code\ Cache/* "Codex code cache"
137+
safe_clean ~/Library/Application\ Support/Codex/GPUCache/* "Codex GPU cache"
138+
safe_clean ~/Library/Application\ Support/Codex/DawnGraphiteCache/* "Codex Dawn cache"
139+
safe_clean ~/Library/Application\ Support/Codex/DawnWebGPUCache/* "Codex WebGPU cache"
132140
}
133141
# Design and creative tools.
134142
clean_design_tools() {
@@ -138,7 +146,6 @@ clean_design_tools() {
138146
safe_clean ~/Library/Caches/com.adobe.*/* "Adobe app caches"
139147
safe_clean ~/Library/Caches/com.figma.Desktop/* "Figma cache"
140148
safe_clean ~/Library/Application\ Support/Adobe/Common/Media\ Cache\ Files/* "Adobe media cache files"
141-
# Raycast cache is protected (clipboard history, images).
142149
}
143150
# Video editing tools.
144151
clean_video_tools() {
@@ -163,6 +170,9 @@ clean_productivity_apps() {
163170
safe_clean ~/Library/Caches/com.filo.client/* "Filo cache"
164171
safe_clean ~/Library/Caches/com.flomoapp.mac/* "Flomo cache"
165172
safe_clean ~/Library/Application\ Support/Quark/Cache/videoCache/* "Quark video cache"
173+
safe_clean ~/Library/Containers/com.ranchero.NetNewsWire-Evergreen/Data/Library/Caches/* "NetNewsWire cache"
174+
safe_clean ~/Library/Containers/com.ideasoncanvas.mindnode/Data/Library/Caches/* "MindNode cache"
175+
safe_clean ~/.cache/kaku/* "Kaku cache"
166176
}
167177
# Music/media players (protect Spotify offline music).
168178
clean_media_players() {
@@ -284,6 +294,18 @@ clean_shell_utils() {
284294
clean_system_utils() {
285295
safe_clean ~/Library/Caches/com.runjuu.Input-Source-Pro/* "Input Source Pro cache"
286296
safe_clean ~/Library/Caches/macos-wakatime.WakaTime/* "WakaTime cache"
297+
# WeType input method (image and dict update cache, not engine or user dict)
298+
safe_clean ~/Library/Application\ Support/WeType/com.onevcat.Kingfisher.ImageCache.WeType/* "WeType image cache"
299+
safe_clean ~/Library/Application\ Support/WeType/DictUpdate/* "WeType dict update cache"
300+
# mihomo-party proxy tool (Electron)
301+
safe_clean ~/Library/Application\ Support/mihomo-party/Cache/* "mihomo-party cache"
302+
safe_clean ~/Library/Application\ Support/mihomo-party/Code\ Cache/* "mihomo-party code cache"
303+
safe_clean ~/Library/Application\ Support/mihomo-party/GPUCache/* "mihomo-party GPU cache"
304+
safe_clean ~/Library/Application\ Support/mihomo-party/DawnGraphiteCache/* "mihomo-party Dawn cache"
305+
safe_clean ~/Library/Application\ Support/mihomo-party/DawnWebGPUCache/* "mihomo-party WebGPU cache"
306+
safe_clean ~/Library/Application\ Support/mihomo-party/logs/* "mihomo-party logs"
307+
# Stash proxy tool
308+
safe_clean ~/Library/Caches/ws.stash.app.mac/* "Stash cache"
287309
}
288310
# Note-taking apps.
289311
clean_note_apps() {
@@ -298,6 +320,9 @@ clean_note_apps() {
298320
clean_launcher_apps() {
299321
safe_clean ~/Library/Caches/com.runningwithcrayons.Alfred/* "Alfred cache"
300322
safe_clean ~/Library/Caches/cx.c3.theunarchiver/* "The Unarchiver cache"
323+
# Raycast: only clean network and FS caches; Clipboard subfolder contains user's clipboard history.
324+
safe_clean ~/Library/Caches/com.raycast.macos/urlcache/* "Raycast URL cache"
325+
safe_clean ~/Library/Caches/com.raycast.macos/fsCachedData/* "Raycast FS cache"
301326
}
302327
# Remote desktop tools.
303328
clean_remote_desktop() {

lib/clean/dev.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -868,6 +868,7 @@ clean_dev_mobile() {
868868
safe_clean ~/.android/cache/* "Android SDK cache"
869869
safe_clean ~/Library/Developer/Xcode/UserData/IB\ Support/* "Xcode Interface Builder cache"
870870
safe_clean ~/.cache/swift-package-manager/* "Swift package manager cache"
871+
safe_clean ~/Library/Caches/org.swift.swiftpm/* "Swift package manager library cache"
871872
# Expo/React Native caches (preserve state.json which contains auth tokens).
872873
safe_clean ~/.expo/expo-go/* "Expo Go cache"
873874
safe_clean ~/.expo/android-apk-cache/* "Expo Android APK cache"
@@ -1069,6 +1070,21 @@ clean_dev_misc() {
10691070
safe_clean ~/Library/Application\ Support/Claude/GPUCache/* "Claude GPU cache"
10701071
safe_clean ~/Library/Application\ Support/Claude/DawnGraphiteCache/* "Claude Dawn cache"
10711072
safe_clean ~/Library/Application\ Support/Claude/DawnWebGPUCache/* "Claude WebGPU cache"
1073+
safe_clean ~/Library/Application\ Support/Claude/sentry/* "Claude sentry cache"
1074+
safe_clean ~/Library/Application\ Support/Claude/pending-uploads/* "Claude pending uploads"
1075+
# Qoder (VS Code fork, Electron)
1076+
safe_clean ~/Library/Application\ Support/Qoder/Cache/* "Qoder cache"
1077+
safe_clean ~/Library/Application\ Support/Qoder/CachedData/* "Qoder cached data"
1078+
safe_clean ~/Library/Application\ Support/Qoder/CachedExtensionVSIXs/* "Qoder extension cache"
1079+
safe_clean ~/Library/Application\ Support/Qoder/Code\ Cache/* "Qoder code cache"
1080+
safe_clean ~/Library/Application\ Support/Qoder/GPUCache/* "Qoder GPU cache"
1081+
safe_clean ~/Library/Application\ Support/Qoder/DawnGraphiteCache/* "Qoder Dawn cache"
1082+
safe_clean ~/Library/Application\ Support/Qoder/DawnWebGPUCache/* "Qoder WebGPU cache"
1083+
safe_clean ~/Library/Application\ Support/Qoder/logs/* "Qoder logs"
1084+
# Prisma ORM engine binaries cache
1085+
safe_clean ~/.cache/prisma/* "Prisma cache"
1086+
# OpenCode AI tool cache
1087+
safe_clean ~/.cache/opencode/* "OpenCode cache"
10721088
}
10731089
# Shell and VCS leftovers.
10741090
clean_dev_shell() {
@@ -1117,6 +1133,8 @@ clean_dev_editors() {
11171133
clean_service_worker_cache "VS Code" "$HOME/Library/Application Support/Code/Service Worker/CacheStorage"
11181134
safe_clean ~/Library/Application\ Support/Code/Service\ Worker/ScriptCache/* "VS Code Service Worker ScriptCache"
11191135
safe_clean ~/Library/Caches/Zed/* "Zed cache"
1136+
safe_clean ~/Library/Caches/copilot/* "GitHub Copilot cache"
1137+
safe_clean ~/.cache/vscode-ripgrep/* "VS Code ripgrep cache"
11201138
safe_clean ~/Library/Caches/Cursor/* "Cursor cache"
11211139
safe_clean ~/Library/Application\ Support/Cursor/CachedData/* "Cursor cached data"
11221140
safe_clean ~/Library/Application\ Support/Cursor/CachedExtensionVSIXs/* "Cursor extension cache"

lib/clean/user.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -670,6 +670,13 @@ clean_app_caches() {
670670
safe_clean ~/Library/Containers/com.apple.geod/Data/tmp/* "Geod temp files"
671671
safe_clean ~/Library/Containers/com.apple.stocks/Data/Library/Caches/* "Stocks cache"
672672
safe_clean ~/Library/Application\ Support/com.apple.wallpaper/aerials/thumbnails/* "Wallpaper aerials thumbnails"
673+
safe_clean ~/Library/Caches/com.apple.helpd/* "macOS Help system cache"
674+
safe_clean ~/Library/Caches/GeoServices/* "Maps geo tile cache"
675+
safe_clean ~/Library/Containers/com.apple.AvatarUI.AvatarPickerMemojiPicker/Data/Library/Caches/* "Memoji picker cache"
676+
safe_clean ~/Library/Containers/com.apple.AMPArtworkAgent/Data/Library/Caches/* "Music album art cache"
677+
safe_clean ~/Library/Containers/com.apple.CoreDevice.CoreDeviceService/Data/Library/Caches/* "CoreDevice service cache"
678+
safe_clean ~/Library/Containers/com.apple.NeptuneOneExtension/Data/Library/Caches/* "Apple Intelligence extension cache"
679+
safe_clean ~/Library/Containers/com.apple.AppleMediaServicesUI.UtilityExtension/Data/tmp/* "Apple Media Services temp files"
673680
local containers_dir="$HOME/Library/Containers"
674681
[[ ! -d "$containers_dir" ]] && return 0
675682
start_section_spinner "Scanning sandboxed apps..."

0 commit comments

Comments
 (0)