Skip to content

Instantly share code, notes, and snippets.

@jiimaho
Last active December 10, 2018 10:17
Show Gist options
  • Save jiimaho/27b059db968c8b145e3d850fb2adb111 to your computer and use it in GitHub Desktop.
Save jiimaho/27b059db968c8b145e3d850fb2adb111 to your computer and use it in GitHub Desktop.
powershell remove dir and obj
function hardClean {
try {
Get-ChildItem .\ -include bin,obj -Recurse | foreach ($_) {
Write-Output "Deleting $_"
remove-item $_.FullName -Force -Recurse
}
}
catch {
Write-Output "error"
}
}
# Cred to https://stackoverflow.com/a/755433/2874896
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment