-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclear-app-cache.sh
More file actions
executable file
·44 lines (34 loc) · 1.15 KB
/
clear-app-cache.sh
File metadata and controls
executable file
·44 lines (34 loc) · 1.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/bin/bash
# Clear All App Caches Script
# Clears all development and system caches for the Loud Mouth app
echo "🧹 Clearing all app caches for Loud Mouth..."
# Clear Cargo build cache
echo "→ Clearing Cargo build cache..."
cd "$(dirname "$0")/src-tauri" && cargo clean
cd "$(dirname "$0")"
# Clear Xcode DerivedData
echo "→ Clearing Xcode DerivedData..."
rm -rf ~/Library/Developer/Xcode/DerivedData/LoudMouth-*
# Clear user icon caches
echo "→ Clearing icon caches..."
rm -rf ~/Library/Caches/com.apple.iconservices
rm -rf ~/Library/Caches/com.apple.dock.iconcache
find ~/Library/Caches -name "*icon*" -type d 2>/dev/null | xargs rm -rf 2>/dev/null
# Clear node_modules cache
echo "→ Clearing node_modules cache..."
rm -rf node_modules/.vite
# Clear dist folder
echo "→ Clearing dist folder..."
rm -rf dist
# Restart Dock
echo "→ Restarting Dock..."
killall Dock 2>/dev/null
# Restart Finder
echo "→ Restarting Finder..."
killall Finder 2>/dev/null
echo ""
echo "✅ All caches cleared successfully!"
echo ""
echo "📝 Note: For system-level icon cache, run manually:"
echo " sudo rm -rf /Library/Caches/com.apple.iconservices.store"
echo ""