explorer.ps1
|
function Stop-Explorer { <# .SYNOPSIS Restarts Windows Explorer. .DESCRIPTION Stops the Windows Explorer process, which (generally) triggers a restart. .NOTES Alias: sx #> [CmdletBinding(SupportsShouldProcess)] Param() if ($PSCmdlet.ShouldProcess("Windows Explorer", "Stop all instances")) { Stop-Process -ProcessName explorer } } New-Alias -Name sx -Value Stop-Explorer -ErrorAction SilentlyContinue | Out-Null |