Created
January 29, 2020 09:08
-
-
Save pulimento/8bfecb74f31f492fa15bdc133acfb5a8 to your computer and use it in GitHub Desktop.
Clear VS project folder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Define files and directories to delete | |
$include = @("*.suo","*.user","*.cache","*.docstates","bin","obj","*.GhostDoc.xml") | |
# Define files and directories to exclude | |
$exclude = @() | |
$items = Get-ChildItem . -recurse -force -include $include -exclude $exclude | |
if ($items) { | |
foreach ($item in $items) { | |
Remove-Item $item.FullName -Force -Recurse -ErrorAction SilentlyContinue | |
Write-Host "Deleted" $item.FullName | |
} | |
} | |
Write-Host "Press any key to continue . . ." | |
$x = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment