mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-04-22 01:48:20 +02:00
Update clear-recycle-bin.ps1
This commit is contained in:
parent
14d7a4b137
commit
90a7f3dda1
@ -1,8 +1,9 @@
|
|||||||
<#
|
<#
|
||||||
.SYNOPSIS
|
.SYNOPSIS
|
||||||
clear-recycle-bin.ps1
|
clear-recycle-bin.ps1
|
||||||
.DESCRIPTION
|
.DESCRIPTION
|
||||||
Removes the content of the recycle bin folder (can not be undo).
|
Removes the content of the recycle bin folder.
|
||||||
|
NOTE: can not be undo!
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> .\clear-recycle-bin.ps1
|
PS> .\clear-recycle-bin.ps1
|
||||||
.NOTES
|
.NOTES
|
||||||
@ -13,7 +14,7 @@
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
Clear-RecycleBin -Confirm:$false
|
Clear-RecycleBin -Confirm:$false
|
||||||
"✔️ recycle bin have been emptied"
|
"✔️ cleared recycle bin"
|
||||||
exit 0
|
exit 0
|
||||||
} catch {
|
} catch {
|
||||||
write-error "⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
write-error "⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
|
||||||
|
Loading…
Reference in New Issue
Block a user