mirror of
https://github.com/smxi/inxi.git
synced 2024-11-17 00:31:19 +00:00
new version: bug fix
A case where pcibusid includes the pre- 0000: appeared, that broke the -N pcibus id handling for -n, which made for no output. Now inxi will just slice off that in the initial lspci creator.
This commit is contained in:
parent
1c38f454b2
commit
41caad5be0
16
inxi
16
inxi
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
########################################################################
|
########################################################################
|
||||||
#### Script Name: inxi
|
#### Script Name: inxi
|
||||||
#### version: 1.7.9
|
#### version: 1.7.10
|
||||||
#### Date: June 22 2011
|
#### Date: June 22 2011
|
||||||
#### Patch Number: 00
|
#### Patch Number: 00
|
||||||
########################################################################
|
########################################################################
|
||||||
|
@ -4096,6 +4096,7 @@ get_lspci_data()
|
||||||
eval $LOGFS
|
eval $LOGFS
|
||||||
local lspci_data="$( lspci -v | gawk '{
|
local lspci_data="$( lspci -v | gawk '{
|
||||||
gsub(/\(prog-if[^)]*\)/,"")
|
gsub(/\(prog-if[^)]*\)/,"")
|
||||||
|
sub(/^0000:/, "", $0) # seen case where the 0000: is prepended, rare, but happens
|
||||||
print
|
print
|
||||||
}' )"
|
}' )"
|
||||||
|
|
||||||
|
@ -4216,7 +4217,8 @@ get_networking_data()
|
||||||
local b_usb_networking='false' temp_array=''
|
local b_usb_networking='false' temp_array=''
|
||||||
|
|
||||||
IFS=$'\n'
|
IFS=$'\n'
|
||||||
A_NETWORK_DATA=( $( echo "$Lspci_Data" | gawk '
|
A_NETWORK_DATA=( $(
|
||||||
|
echo "$Lspci_Data" | gawk '
|
||||||
BEGIN {
|
BEGIN {
|
||||||
IGNORECASE=1
|
IGNORECASE=1
|
||||||
counter=0 # required to handle cases of > 1 instance of the same chipset
|
counter=0 # required to handle cases of > 1 instance of the same chipset
|
||||||
|
@ -4283,7 +4285,8 @@ get_networking_data()
|
||||||
print a[j] "," useDrivers "," usePorts "," useModules, "," usePciBusId
|
print a[j] "," useDrivers "," usePorts "," useModules, "," usePciBusId
|
||||||
j++
|
j++
|
||||||
}
|
}
|
||||||
}') )
|
}'
|
||||||
|
) )
|
||||||
IFS="$ORIGINAL_IFS"
|
IFS="$ORIGINAL_IFS"
|
||||||
b_usb_networking=$( get_networking_usb_data )
|
b_usb_networking=$( get_networking_usb_data )
|
||||||
|
|
||||||
|
@ -7481,15 +7484,16 @@ print_system_data()
|
||||||
if [[ $B_EXTRA_DATA == 'true' ]];then
|
if [[ $B_EXTRA_DATA == 'true' ]];then
|
||||||
gcc_string=$( get_gcc_version )
|
gcc_string=$( get_gcc_version )
|
||||||
if [[ -n $gcc_string ]];then
|
if [[ -n $gcc_string ]];then
|
||||||
gcc_string=" ${C1}gcc${C2} $gcc_string"
|
gcc_string="${C1}gcc${C2} $gcc_string, "
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
# check for 64 bit first
|
# check for 64 bit first
|
||||||
if [[ -n $( uname -m | grep -o 'x86_64' ) ]];then
|
if [[ -n $( uname -m | grep -o 'x86_64' ) ]];then
|
||||||
bits="(64 bit$gcc_string)"
|
bits="64 bit"
|
||||||
else
|
else
|
||||||
bits="(32 bit$gcc_string)"
|
bits="32 bit"
|
||||||
fi
|
fi
|
||||||
|
bits="(${gcc_string}${bits})"
|
||||||
if [[ $B_SHOW_HOST == 'true' ]];then
|
if [[ $B_SHOW_HOST == 'true' ]];then
|
||||||
if [[ -z $HOSTNAME ]];then
|
if [[ -z $HOSTNAME ]];then
|
||||||
if [[ -n $( type p hostname ) ]];then
|
if [[ -n $( type p hostname ) ]];then
|
||||||
|
|
Loading…
Reference in a new issue