Update check-os.ps1

This commit is contained in:
Markus Fleschutz 2022-12-04 19:15:34 +01:00
parent 656db06ccc
commit 0904e73197

View File

@ -27,7 +27,7 @@ try {
$InstallDate = $OSDetails.InstallDate
$ProductKey = (Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" -Name BackupProductKeyDefault).BackupProductKeyDefault
"$Name ($Arch, v$Version, S/N $Serial, key $ProductKey) since $($InstallDate.ToShortDateString())"
"$Name ($Arch, v$Version, S/N $Serial, P/K $ProductKey) since $($InstallDate.ToShortDateString())"
}
exit 0 # success
} catch {