mirror of
https://github.com/smxi/inxi.git
synced 2024-11-17 00:31:19 +00:00
bug fix, added system line
This commit is contained in:
parent
5f4b95dfa3
commit
6937b57028
31
inxi
31
inxi
|
@ -1,7 +1,7 @@
|
|||
#!/bin/bash
|
||||
########################################################################
|
||||
#### Script Name: inxi
|
||||
#### version: 1.5.97
|
||||
#### version: 1.5.98
|
||||
#### Date: June 7 2011
|
||||
########################################################################
|
||||
#### SPECIAL THANKS
|
||||
|
@ -5940,7 +5940,7 @@ print_machine_data()
|
|||
local bios_vendor='' bios_version='' bios_date=''
|
||||
local system_vendor='' product_name='' product_version='' product_serial='' product_uuid=''
|
||||
local chassis_vendor='' chassis_type='' chassis_version='' chassis_serial=''
|
||||
local b_skip_system='false'
|
||||
local b_skip_system='false' b_skip_chassis='false'
|
||||
# set A_MACHINE_DATA
|
||||
get_machine_data
|
||||
|
||||
|
@ -5968,9 +5968,9 @@ print_machine_data()
|
|||
fi
|
||||
if [[ $B_EXTRA_EXTRA_DATA == 'true' ]];then
|
||||
if [[ -n ${A_MACHINE_DATA[5]} && -n ${A_MACHINE_DATA[14]} && ${A_MACHINE_DATA[14]} == ${A_MACHINE_DATA[5]} ]];then
|
||||
:
|
||||
else
|
||||
if [[ -n ${A_MACHINE_DATA[12]} ]];then
|
||||
b_skip_chassis='true'
|
||||
fi
|
||||
if [[ -n ${A_MACHINE_DATA[12]} && $b_skip_chassis != 'true' ]];then
|
||||
chassis_vendor="${C1}Chassis${C2} ${A_MACHINE_DATA[12]}"
|
||||
if [[ -n ${A_MACHINE_DATA[13]} ]];then
|
||||
chassis_type=${A_MACHINE_DATA[13]}
|
||||
|
@ -5988,7 +5988,6 @@ print_machine_data()
|
|||
chassis_line="$chassis_vendor ${C1}type${C2} $chassis_type ${C1}version${C2} $chassis_version$chassis_serial"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
if [[ -n ${A_MACHINE_DATA[5]} ]];then
|
||||
mobo_vendor=${A_MACHINE_DATA[5]}
|
||||
else
|
||||
|
@ -6030,7 +6029,25 @@ print_machine_data()
|
|||
system_line=$mobo_line
|
||||
mobo_line=''
|
||||
else
|
||||
system_line=
|
||||
if [[ -n ${A_MACHINE_DATA[0]} ]];then
|
||||
system_vendor=${A_MACHINE_DATA[0]}
|
||||
else
|
||||
system_vendor='N/A'
|
||||
fi
|
||||
if [[ -n ${A_MACHINE_DATA[1]} ]];then
|
||||
product_name=${A_MACHINE_DATA[1]}
|
||||
else
|
||||
product_name='N/A'
|
||||
fi
|
||||
if [[ -n ${A_MACHINE_DATA[2]} ]];then
|
||||
product_version=${A_MACHINE_DATA[2]}
|
||||
else
|
||||
product_version='N/A'
|
||||
fi
|
||||
if [[ -n ${A_MACHINE_DATA[3]} && $B_OUTPUT_FILTER != 'true' ]];then
|
||||
product_serial=" ${C1}serial${C2} ${A_MACHINE_DATA[3]} "
|
||||
fi
|
||||
system_line="${C1}System${C2} $system_vendor ${C1}product${C2} $product_name ${C1}version${C2} $product_version$product_serial"
|
||||
fi
|
||||
IFS="$ORIGINAL_IFS"
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue