Skip to content

Instantly share code, notes, and snippets.

@klintron
Created April 15, 2020 05:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save klintron/e010339c82ac645af17ccc76c6a1bd71 to your computer and use it in GitHub Desktop.
Save klintron/e010339c82ac645af17ccc76c6a1bd71 to your computer and use it in GitHub Desktop.
$timeout = new-timespan -Minutes 1
$sw = [diagnostics.stopwatch]::StartNew()
while ($sw.elapsed -lt $timeout){
Disable-NetAdapter -Name "Wi-Fi" -Confirm:$False
write-host $sw.elapsed
start-sleep -seconds 1
}
Enable-NetAdapter -Name "Wi-Fi"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment