feat: script originel

This commit is contained in:
Simon404 2023-12-22 20:00:00 +01:00
parent b1938e8c81
commit e357da5802
1 changed files with 9 additions and 0 deletions

9
Clear-MSTeamsCache.ps1 Executable file
View File

@ -0,0 +1,9 @@
$SamAccountName = Read-Host -Prompt "SamAccountName"
$BasePath = "C:\Users"
$FoldersToDelete = @("$BasePath\$SamAccountName\AppData\Roaming\Teams","$BasePath\$SamAccountName\AppData\Roaming\Microsoft\Teams","$BasePath\$SamAccountName\AppData\Local\Packages\Microsoft.AAD.BrokerPlugin_cw5n1h2txyewy","$BasePath\$SamAccountName\AppData\Local\Microsoft\OneAuth","$BasePath\$SamAccountName\AppData\Local\Microsoft\IdentityCache")
foreach ($IndividualFolder in $FoldersToDelete) {
Remove-Item -Recurse -Force -Path $IndividualFolder
}