Add domain to the collected information
This commit is contained in:
parent
93b2bf9180
commit
4ff0c92217
@ -57,6 +57,7 @@ function Find-Computer-Info {
|
|||||||
|
|
||||||
#Init array for storing computer's data
|
#Init array for storing computer's data
|
||||||
$computer_info = @("HOSTNAME:", $cs.Name,
|
$computer_info = @("HOSTNAME:", $cs.Name,
|
||||||
|
"Domain:", $cs.Domain,
|
||||||
"OS Version:", $computer_os_info.Caption,
|
"OS Version:", $computer_os_info.Caption,
|
||||||
"OS Architecture:", $computer_os_info.OSArchitecture,
|
"OS Architecture:", $computer_os_info.OSArchitecture,
|
||||||
"Manufacture:", $cs.manufacturer,
|
"Manufacture:", $cs.manufacturer,
|
||||||
@ -94,6 +95,7 @@ function Show-Computer-Info { # Function writes by default to stdout. If given a
|
|||||||
|
|
||||||
function Find-Computer-Info_7 {
|
function Find-Computer-Info_7 {
|
||||||
$cs_hostname = wmic computersystem get name
|
$cs_hostname = wmic computersystem get name
|
||||||
|
$cs_domain = wmic computersystem get Domain
|
||||||
$os_name = wmic os get Caption
|
$os_name = wmic os get Caption
|
||||||
$os_arch = wmic computersystem get SystemType
|
$os_arch = wmic computersystem get SystemType
|
||||||
$cpu_name = wmic cpu get name
|
$cpu_name = wmic cpu get name
|
||||||
@ -105,6 +107,7 @@ function Find-Computer-Info_7 {
|
|||||||
|
|
||||||
$computer_info_7 = @(
|
$computer_info_7 = @(
|
||||||
"HOSTNAME:", $cs_hostname[2],
|
"HOSTNAME:", $cs_hostname[2],
|
||||||
|
"Domain:", $cs_domain[2],
|
||||||
"OS Version:", $os_name[2],
|
"OS Version:", $os_name[2],
|
||||||
"OS Architecture:", $os_arch[2],
|
"OS Architecture:", $os_arch[2],
|
||||||
"Manufacture:", $cs_manufacturer[2],
|
"Manufacture:", $cs_manufacturer[2],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user