systeminfo > C:\specs.txt

Get-ComputerInfo | Export-Clixml -Path "C:\specs.xml" Or human-readable: