Skip to content

Instantly share code, notes, and snippets.

@sahwar
Forked from aherrman/toggleWireless.ps1
Created June 4, 2020 02:44
Show Gist options
  • Select an option

  • Save sahwar/e8cbbe1f7e6138dbdebf7ff7c6df2d07 to your computer and use it in GitHub Desktop.

Select an option

Save sahwar/e8cbbe1f7e6138dbdebf7ff7c6df2d07 to your computer and use it in GitHub Desktop.
$devid = "*DEV_4236"
$status = devcon status $devid | Select-String "running"
if($status -eq $null)
{
write-host "Enabling wireless"
devcon enable $devid
}
else
{
write-host "Disabling wireless"
devcon disable $devid
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment