mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-15 11:17:53 +01:00
tools: add wmi monitor info powershell script
This commit is contained in:
committed by
Andrey Nekrasov
parent
3c76942799
commit
e0d6c2a4cd
6
tools/monitor_info_report/print_wmi_monitor_info.ps1
Normal file
6
tools/monitor_info_report/print_wmi_monitor_info.ps1
Normal file
@@ -0,0 +1,6 @@
|
||||
$output = gwmi WmiMonitorID -Namespace root\wmi | ForEach-Object { ($_.UserFriendlyName -notmatch 0 | foreach {[char]$_}) -join ""; ($_.SerialNumberID -notmatch 0 | foreach {[char]$_}) -join ""; $_.InstanceName + "`n" } | Out-String
|
||||
Write-Host $output
|
||||
$LogTime = Get-Date -Format "MM-dd-yyyy_hh-mm-ss"
|
||||
$LogFile = 'wmi_monitor_info-' + $LogTime + ".log"
|
||||
Write-Output $output | Out-File $LogFile
|
||||
|
||||
Reference in New Issue
Block a user