Add list-cpu.ps1, list-motherboard.ps1, and list-ram.ps1

This commit is contained in:
Markus Fleschutz
2022-10-04 15:19:00 +02:00
parent da9c58db56
commit b12f9c9f45
3 changed files with 60 additions and 0 deletions

20
Scripts/list-cpu.ps1 Normal file
View File

@ -0,0 +1,20 @@
<#
.SYNOPSIS
Lists CPU details
.DESCRIPTION
This PowerShell script lists the CPU details.
.EXAMPLE
PS> ./list-cpu
.LINK
https://github.com/fleschutz/PowerShell
.NOTES
Author: Markus Fleschutz | License: CC0
#>
try {
Get-WmiObject -Class Win32_Processor
exit 0 # success
} catch {
"⚠️ Error in line $($_.InvocationInfo.ScriptLineNumber): $($Error[0])"
exit 1
}