-
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathuninstall-teams.sh
executable file
·39 lines (32 loc) · 1.31 KB
/
uninstall-teams.sh
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
#!/usr/bin/env sh
# This script uninstalls Microsoft Teams classic and its related data from a Mac.
# Path to Microsoft Teams classic app
TEAMS_APP_PATH="/Applications/Microsoft Teams classic.app"
# Paths to Microsoft Teams related data and cache
TEAMS_DATA_PATHS=(
"$HOME/Library/Caches/com.microsoft.teams"
"$HOME/Library/Caches/com.microsoft.teams.shipit"
"$HOME/Library/Application Support/Microsoft/Teams"
"$HOME/Library/Application Support/Microsoft/Teams/Application Cache/Cache"
"$HOME/Library/Application Support/Microsoft/Teams/blob_storage"
"$HOME/Library/Application Support/Microsoft/Teams/Cache"
"$HOME/Library/Application Support/Microsoft/Teams/databases"
"$HOME/Library/Application Support/Microsoft/Teams/GPUCache"
"$HOME/Library/Application Support/Microsoft/Teams/IndexedDB"
"$HOME/Library/Application Support/Microsoft/Teams/Local Storage"
"$HOME/Library/Application Support/Microsoft/Teams/tmp"
)
remove_item() {
if [ -d "$1" ]; then
echo "Deleting $1..."
rm -rf "$1"
echo "$1 has been deleted."
else
echo "$1 is not present."
fi
}
remove_item "$TEAMS_APP_PATH"
for path in "${TEAMS_DATA_PATHS[@]}"; do
remove_item "$path"
done
echo "Microsoft Teams classic and associated data have been removed, if they were present."