New version, man page. Fixes, enhancements, changes.

Thanks:
1. AntiX forums, for testing -C --admin, suggestions, always helpful.

Bugs:
1. Added switch to set @ps_gui, I forgot case where info block was only thing
that used ps_gui (Nitrux kde nomad latte case). This led to no info: data if
other ps_gui switches not activated. Now each block that can use it activates it.

Fixes:
1. To clarify issue #161 added help/man explanation on how to get colors in cases
where you want to preserve colors for piped or redirected output. Thanks fugo.
2. LMDE 3.0 released, slightly different system base handling, so refactored to
add Debian version, see enhancement 2. Tested on some old vm instances, improved
old system Debian system base id, but it's empirical, distro by distro, there is
no rule I can use to automatically do it, sadly.
3. 'Motherboard' sensors field name added, a few small tweaks to sensors. This
was in response to issue #159, which also raised a problem I was not really
aware of, user generated sensor config files, that can have totally random
field names. Longer term solution, start getting data from sys to pad out
lm-sensors data, or to handle cases where no lm-sensors installed.
4. Fixed kwin_11 and kwin_wayland compositor print names, I'd left out the _,
which made it look strange, like there were two compositors or something.
5. Fixed latte-dock ID, I thought the program name when running was latte, not
latte-dock. inxi checks for both now. Thanks Nitrux for exposing that in vm test.
6. Sensors: added in a small filter to motherboard temp, avoid values that are
too high, like SYSTIN: 118 C, filters out to only use < 90 C. Very unlikely a
mobo would be more than 90C unless it's a mistake or about to melt. This may
correct anoymous debugger dataset report from rakasunka.

Enhancements:
1. Added --admin to -v 8 and to --debugger 2x
2. Expanded system base to use Debian version tool, like the ubuntu one, that
lets me match version number to codename. The ubuntu one matches code names to
release dates. Added Neptune, PureOS, Sparky, Tails, to new Debian system base
handler.
3. Big enhancement: --admin -C now shows a nice report on cpu vulnerabilities,
and has a good error message if no data found. Report shows:
Vulnerabilities: Type: [e.g. meltdown] status/mitigation: text explanation.
Note: 'status' is for when no mitigation, either not applicable,  or is vulnerable.
'mitigation' is when it's handled, and how. Thanks issue #160 Vascom from Fedora
for that request.
4. The never-ending saga of disk vendor IDs continues. More obscure vendors,
more matches to existing vendors. Thanks linuxlite/linux hardware database

Changes:
1. Reordered usb output, I don't know why I had Hubs and Devices use different
ordering and different -x switch priorities, that was silly, and made it hard to
read.
Now shows:
Device/Hub: bus-id-port-id[.port-id]:device-id info: [product info]
type/ports: [devices/hubs] usb: [type, speed]
-x adds drivers for devices, and usb: speed is now default for devices, same as
Hubs. Why I had those different is beyond me.
The USB ordering is now more sensible, the various components of each
matching whether hub or device.

Unfixable or Won't Fix:
1. Unable to detect Nomad desktop. As far as I can tell, Nomad is only a theme
applied to KDE Plasma, there is no program by that name detectable, only a
reference in ps aux to a theme called nomad.
2. Nitrux system base ID will not work until they correct their /etc/os-release file.
3. Tails live cd for some inexplicable reason uses non standard /etc/os-release
field names, which forces me to either do a custom detection just for them, or for
them to fix this bug. I opted for ignoring it, if I let each distro break standard
formats then try to work around it, the distro ID will grow to be a 1000 lines long
easily. Will file distro bug reports when I find these from now on.

Samples:

This shows the corrected, cleaned up, consistent usb output:

inxi -y80 --usb
USB:
  Hub: 1-0:1 info: Full speed (or root) Hub ports: 14 usb: 2.0
  Hub: 1-3:2 info: Atmel 4-Port Hub ports: 4 usb: 1.1
  Device-1: 1-3.2:4 info: C-Media Audio Adapter (Planet UP-100 Genius G-Talk)
  type: Audio,HID usb: 1.1
  Device-2: 1-4:3 info: Wacom Graphire 2 4x5 type: Mouse usb: 1.1
  Device-3: 1-10:5 info: Tangtop HID Keyboard type: Keyboard,Mouse usb: 1.1
  Device-4: 1-13:7 info: Canon CanoScan LiDE 110 type: <vendor specific>
  usb: 2.0
  Device-5: 1-14:8 info: Apple Ethernet Adapter [A1277] type: Network usb: 2.0
  Hub: 2-0:1 info: Full speed (or root) Hub ports: 8 usb: 3.1
  Hub: 3-0:1 info: Full speed (or root) Hub ports: 2 usb: 2.0
  Hub: 4-0:1 info: Full speed (or root) Hub ports: 2 usb: 3.1
  Hub: 5-0:1 info: Full speed (or root) Hub ports: 4 usb: 2.0
  Hub: 6-0:1 info: Full speed (or root) Hub ports: 4 usb: 3.0

inxi -y80 --usb -xxxz
USB:
  Hub: 1-0:1 info: Full speed (or root) Hub ports: 14 usb: 2.0
  chip ID: 1d6b:0002
  Hub: 1-3:2 info: Atmel 4-Port Hub ports: 4 usb: 1.1 chip ID: 03eb:0902
  Device-1: 1-3.2:4 info: C-Media Audio Adapter (Planet UP-100 Genius G-Talk)
  type: Audio,HID driver: cm109,snd-usb-audio interfaces: 4 usb: 1.1
  chip ID: 0d8c:000e
  Device-2: 1-4:3 info: Wacom Graphire 2 4x5 type: Mouse driver: usbhid,wacom
  interfaces: 1 usb: 1.1 chip ID: 056a:0011
  Device-3: 1-10:5 info: Tangtop HID Keyboard type: Keyboard,Mouse
  driver: hid-generic,usbhid interfaces: 2 usb: 1.1 chip ID: 0d3d:0001
  Device-4: 1-13:7 info: Canon CanoScan LiDE 110 type: <vendor specific>
  driver: N/A interfaces: 1 usb: 2.0 chip ID: 04a9:1909
  Device-5: 1-14:8 info: Apple Ethernet Adapter [A1277] type: Network
  driver: asix interfaces: 1 usb: 2.0 chip ID: 05ac:1402 serial: <filter>
  Hub: 2-0:1 info: Full speed (or root) Hub ports: 8 usb: 3.1
  chip ID: 1d6b:0003
  Hub: 3-0:1 info: Full speed (or root) Hub ports: 2 usb: 2.0
  chip ID: 1d6b:0002
  Hub: 4-0:1 info: Full speed (or root) Hub ports: 2 usb: 3.1
  chip ID: 1d6b:0003
  Hub: 5-0:1 info: Full speed (or root) Hub ports: 4 usb: 2.0
  chip ID: 1d6b:0002
  Hub: 6-0:1 info: Full speed (or root) Hub ports: 4 usb: 3.0
  chip ID: 1d6b:0003
This commit is contained in:
Harald Hope 2018-09-07 13:58:55 -07:00
parent 59e988c9e2
commit e78e37a1e1
3 changed files with 297 additions and 50 deletions

191
inxi
View file

@ -31,8 +31,8 @@ use POSIX qw(uname strftime ttyname);
## INXI INFO ## ## INXI INFO ##
my $self_name='inxi'; my $self_name='inxi';
my $self_version='3.0.22'; my $self_version='3.0.23';
my $self_date='2018-08-28'; my $self_date='2018-09-07';
my $self_patch='00'; my $self_patch='00';
## END INXI INFO ## ## END INXI INFO ##
@ -1776,13 +1776,15 @@ sub system_files {
'/var/run/dmesg.boot', '/var/run/dmesg.boot',
); );
copy_files(\@files,'system-bsd'); copy_files(\@files,'system-bsd');
@files = main::globber('/sys/devices/system/cpu/vulnerabilities/*');
copy_files(\@files,'security');
} }
## SELF EXECUTE FOR LOG/OUTPUT ## SELF EXECUTE FOR LOG/OUTPUT
sub run_self { sub run_self {
print "Creating $self_name output file now. This can take a few seconds...\n"; print "Creating $self_name output file now. This can take a few seconds...\n";
print "Starting $self_name from: $self_path\n"; print "Starting $self_name from: $self_path\n";
my $i = ($option eq 'main-full')? ' -i' : ''; my $i = ($option eq 'main-full')? ' -i' : '';
my $cmd = "$self_path/$self_name -FRfrploudmxxx$i -c 0 --usb --slots --debug 10 -y 120 > $data_dir/$self_name-FRfrploudmxxxyusbslots120.txt 2>&1"; my $cmd = "$self_path/$self_name -FRfrploudmxxx$i --admin --usb --slots --debug 10 -y 120 > $data_dir/$self_name-FRfrploudmxxxy-usb-slots-admin120.txt 2>&1";
system($cmd); system($cmd);
copy($log_file, "$data_dir") or main::error_handler('copy-failed', "$log_file", "$!"); copy($log_file, "$data_dir") or main::error_handler('copy-failed', "$log_file", "$!");
system("$self_path/$self_name --recommends -y 120 > $data_dir/$self_name-recommends-120.txt 2>&1"); system("$self_path/$self_name --recommends -y 120 > $data_dir/$self_name-recommends-120.txt 2>&1");
@ -2077,7 +2079,7 @@ sub upload_file {
if ($host && ( $file_path && -e $file_path ) ){ if ($host && ( $file_path && -e $file_path ) ){
# NOTE: important: must explicitly set to passive true/1 # NOTE: important: must explicitly set to passive true/1
$ftp = Net::FTP->new($host, Debug => 0, Passive => 1); $ftp = Net::FTP->new($host, Debug => 0, Passive => 1) || main::error_handler('ftp-connect', $ftp->message);
$ftp->login($user, $pass) || main::error_handler('ftp-login', $ftp->message); $ftp->login($user, $pass) || main::error_handler('ftp-login', $ftp->message);
$ftp->binary(); $ftp->binary();
$ftp->cwd($dir); $ftp->cwd($dir);
@ -2330,10 +2332,12 @@ sub error_handler {
## FTP ## FTP
elsif ( $err eq 'ftp-bad-path' ) { elsif ( $err eq 'ftp-bad-path' ) {
$errno=70; "Unable to locate for FTP upload file:\n$one" } $errno=70; "Unable to locate for FTP upload file:\n$one" }
elsif ( $err eq 'ftp-connect' ) {
$errno=71; "There was an error with connection to ftp server: $one" }
elsif ( $err eq 'ftp-login' ) { elsif ( $err eq 'ftp-login' ) {
$errno=71; "There was an error with login to ftp server: $one" } $errno=72; "There was an error with login to ftp server: $one" }
elsif ( $err eq 'ftp-upload' ) { elsif ( $err eq 'ftp-upload' ) {
$errno=72; "There was an error with upload to ftp server: $one" } $errno=73; "There was an error with upload to ftp server: $one" }
## Modules ## Modules
elsif ( $err eq 'required-module' ) { elsif ( $err eq 'required-module' ) {
$errno=80; $b_recommends=1; "The required $one Perl module is not installed:\n$two" } $errno=80; $b_recommends=1; "The required $one Perl module is not installed:\n$two" }
@ -3935,6 +3939,7 @@ sub get_options{
$extra = 3; $extra = 3;
} }
if ($arg >= 8 ){ if ($arg >= 8 ){
$b_admin = 1;
$b_downloader = 1; $b_downloader = 1;
$show{'slot'} = 1; $show{'slot'} = 1;
$show{'process'} = 1; $show{'process'} = 1;
@ -4308,7 +4313,8 @@ sub show_options {
['1', '-b', '--basic', "Basic output, short form. Same as $self_name^-v^2." ], ['1', '-b', '--basic', "Basic output, short form. Same as $self_name^-v^2." ],
['1', '-B', '--battery', "System battery info, including charge and condition, plus ['1', '-B', '--battery', "System battery info, including charge and condition, plus
extra info (if battery present)." ], extra info (if battery present)." ],
['1', '-c', '--color', "Set color scheme (0-42). Example:^$self_name^-c^11" ], ['1', '-c', '--color', "Set color scheme (0-42). For piped or redirected output,
you must use an explicit color selector. Example:^$self_name^-c^11" ],
['1', '', '', "Color selectors let you set the config file value for the ['1', '', '', "Color selectors let you set the config file value for the
selection (NOTE: IRC and global only show safe color set)" ], selection (NOTE: IRC and global only show safe color set)" ],
['2', '94', '', "Console, out of X" ], ['2', '94', '', "Console, out of X" ],
@ -4360,7 +4366,7 @@ sub show_options {
/ /boot /home /opt /tmp /usr /usr/home /var /var/log /var/tmp. Use -p to see all / /boot /home /opt /tmp /usr /usr/home /var /var/log /var/tmp. Use -p to see all
mounted ${partition_string}s." ], mounted ${partition_string}s." ],
['1', '-r', '--repos', "Distro repository data. Supported repo types: APK, ['1', '-r', '--repos', "Distro repository data. Supported repo types: APK,
APT, EOPKG, PACMAN, PACMAN-G2, PISI, PORTAGE, PORTS (BSDs), SLACKPKG, APT, EOPKG, PACMAN, PACMAN-G2, PISI, PORTAGE, PORTS (BSDs), SLACKPKG, TCE,
URPMQ, YUM/ZYPP." ], URPMQ, YUM/ZYPP." ],
['1', '-R', '--raid', "RAID data. Shows RAID devices, states, levels, ['1', '-R', '--raid', "RAID data. Shows RAID devices, states, levels,
and components. md-raid: If device is resyncing, also shows resync progress line." ], and components. md-raid: If device is resyncing, also shows resync progress line." ],
@ -4396,7 +4402,7 @@ sub show_options {
optical drive (-d), USB (--usb), full RAID; triggers -xx." ], optical drive (-d), USB (--usb), full RAID; triggers -xx." ],
['2', '7', '', "Network IP data (-i); triggers -xxx."], ['2', '7', '', "Network IP data (-i); triggers -xxx."],
['2', '8', '', "Everything available, including repos (-r), processes ['2', '8', '', "Everything available, including repos (-r), processes
(-tcm), PCI slots (--slots)."], (-tcm), PCI slots (--slots), extra admin data (--admin)."],
); );
push @data, @rows; push @data, @rows;
# if distro maintainers don't want the weather feature disable it # if distro maintainers don't want the weather feature disable it
@ -4444,7 +4450,7 @@ sub show_options {
and detected)" ], and detected)" ],
['2', '-t', '', "Adds memory use output to CPU (-xt c), and CPU use to ['2', '-t', '', "Adds memory use output to CPU (-xt c), and CPU use to
memory (-xt m)." ], memory (-xt m)." ],
['2', '--usb', '', "For Devices, shows USB version/speed and driver." ], ['2', '--usb', '', "For Device: driver." ],
); );
push @data, @rows; push @data, @rows;
if ( $b_weather ){ if ( $b_weather ){
@ -4505,7 +4511,7 @@ sub show_options {
['2', '-S', '', "Panel/tray/bar/dock info in desktop output, if in X (like lxpanel, ['2', '-S', '', "Panel/tray/bar/dock info in desktop output, if in X (like lxpanel,
xfce4-panel, mate-panel); (if available) dm version number, window manager xfce4-panel, mate-panel); (if available) dm version number, window manager
version number." ], version number." ],
['2', '--usb', '', "For devices: serial number (if present), interface count." ], ['2', '--usb', '', "For Device: serial number (if present), interface count." ],
); );
push @data, @rows; push @data, @rows;
if ( $b_weather ){ if ( $b_weather ){
@ -4516,7 +4522,7 @@ sub show_options {
@rows = ( @rows = (
['1', '', '--admin', "Adds advanced sys admin data (only works with ['1', '', '--admin', "Adds advanced sys admin data (only works with
verbose or line output, not short form):" ], verbose or line output, not short form):" ],
['2', '-C', '', "If available: CPU errata (bugs); family, model-id, stepping - format: ['2', '-C', '', "If available: CPU vulnerabilities (bugs); family, model-id, stepping - format:
hex (decimal) if greater than 9, otherwise hex; microcode - format: hex." ], hex (decimal) if greater than 9, otherwise hex; microcode - format: hex." ],
['1', '-y', '--width', "Output line width max (integer >= 80). Overrides IRC/Terminal ['1', '-y', '--width', "Output line width max (integer >= 80). Overrides IRC/Terminal
settings or actual widths. Example:^inxi^-y^130" ], settings or actual widths. Example:^inxi^-y^130" ],
@ -5254,6 +5260,7 @@ sub row_defaults {
'arm-pci' => "No ARM data found for this feature.", 'arm-pci' => "No ARM data found for this feature.",
'battery-data' => "No system battery data found. Is one present?", 'battery-data' => "No system battery data found. Is one present?",
'battery-data-sys' => "No /sys data found. Old system?", 'battery-data-sys' => "No /sys data found. Old system?",
'cpu-bugs-null' => "No CPU vulnerability/bugs data available.",
'cpu-model-null' => "Model N/A", 'cpu-model-null' => "Model N/A",
'cpu-speeds' => "No speed data found for $id cores.", 'cpu-speeds' => "No speed data found for $id cores.",
'darwin-feature' => "Feature not supported iu Darwin/OSX.", 'darwin-feature' => "Feature not supported iu Darwin/OSX.",
@ -6557,14 +6564,32 @@ sub create_output_full {
},); },);
@rows = (@rows,@data); @rows = (@rows,@data);
} }
if ($b_admin && $cpu{'bugs'}){ if ($b_admin){
my @bugs = split /\s+/, $cpu{'bugs'}; my @bugs = cpu_bugs_sys();
@bugs = sort(@bugs); my $value = '';
my $bug = join ' ', @bugs; if (!@bugs){
if ( $cpu{'bugs'}){
my @proc_bugs = split /\s+/, $cpu{'bugs'};
@proc_bugs = sort(@proc_bugs);
$value = join ' ', @bugs;
}
else {
$value = main::row_defaults('cpu-bugs-null');
}
}
@data = ({ @data = ({
main::key($num++,'Errata') => $bug, main::key($num++,'Vulnerabilities') => $value,
},); },);
@rows = (@rows,@data); @rows = (@rows,@data);
if (@bugs){
$j = $#rows;
foreach my $ref (@bugs){
my @bug = @$ref;
$rows[$j]{main::key($num++,'Type')} = $bug[0];
$rows[$j]{main::key($num++,$bug[1])} = $bug[2];
$j++;
}
}
} }
eval $end if $b_log; eval $end if $b_log;
return @rows; return @rows;
@ -6872,6 +6897,7 @@ sub data_cpuinfo {
} }
} }
if ($b_admin ){ if ($b_admin ){
# note: not used unless maybe /sys data missing?
if ( !$cpu{'bugs'} && $line[0] eq 'bugs'){ if ( !$cpu{'bugs'} && $line[0] eq 'bugs'){
$cpu{'bugs'} = $line[1]; $cpu{'bugs'} = $line[1];
} }
@ -7316,6 +7342,26 @@ sub cpu_properties {
eval $end if $b_log; eval $end if $b_log;
return %cpu_properties; return %cpu_properties;
} }
sub cpu_bugs_sys {
eval $start if $b_log;
my (@bugs,$type,$value);
return if ! -d '/sys/devices/system/cpu/vulnerabilities/';
my @items = main::globber('/sys/devices/system/cpu/vulnerabilities/*');
if (@items){
foreach (@items){
$value = (main::reader($_))[0];
$type = ($value =~ /^Mitigation:/) ? 'mitigation': 'status';
$_ =~ s/.*\/([^\/]+)$/$1/;
$value =~ s/Mitigation: //;
@bugs = (@bugs,[($_,$type,$value)]);
}
}
main::log_data('dump','@bugs',\@bugs) if $b_log;
# print Data::Dumper::Dumper \@bugs;
eval $end if $b_log;
return @bugs;
}
sub cpu_speeds { sub cpu_speeds {
eval $start if $b_log; eval $start if $b_log;
my (@processors) = @_; my (@processors) = @_;
@ -8408,7 +8454,7 @@ sub device_vendor {
['(SanDisk|^SDS[S]?[DQ]|^SL([0-9]+)G|^AFGCE|ULTRA\sFIT|Clip Sport|Cruzer)','SanDisk','SanDisk',''], ['(SanDisk|^SDS[S]?[DQ]|^SL([0-9]+)G|^AFGCE|ULTRA\sFIT|Clip Sport|Cruzer)','SanDisk','SanDisk',''],
['^STEC\b','^STEC\b','STEC',''], # ssd drive, must come before seagate ST test ['^STEC\b','^STEC\b','STEC',''], # ssd drive, must come before seagate ST test
# real, SSEAGATE Backup+; XP1600HE30002 # real, SSEAGATE Backup+; XP1600HE30002
['(^ST[^T]|[S]?SEAGATE|^X[AFP]|^BUP|Expansion Desk|GoFlex)','[S]?SEAGATE','Seagate',''], ['(^ST[^T]|[S]?SEAGATE|^X[AFP]|^BUP|Expansion Desk|GoFlex|Backup(\+|\s?Plus)\s?Hub)','[S]?SEAGATE','Seagate',''],
['^(WD|Western Digital|My (Book|Passport)|\d*LPCX|Elements|M000|EARX|EFRX|\d*EAVS)','(^WDC|Western Digital)','Western Digital',''], ['^(WD|Western Digital|My (Book|Passport)|\d*LPCX|Elements|M000|EARX|EFRX|\d*EAVS)','(^WDC|Western Digital)','Western Digital',''],
## Then better known ones ## ## Then better known ones ##
['^(A-DATA|ADATA|AXN)','^(A-DATA|ADATA)','A-Data',''], ['^(A-DATA|ADATA|AXN)','^(A-DATA|ADATA)','A-Data',''],
@ -8421,7 +8467,7 @@ sub device_vendor {
['^(HGST|Touro)','^HGST','HGST (Hitachi)',''], # HGST HUA ['^(HGST|Touro)','^HGST','HGST (Hitachi)',''], # HGST HUA
['^(Hitachi|HDS|HDT|IC|HT|HU)','^Hitachi','Hitachi',''], ['^(Hitachi|HDS|HDT|IC|HT|HU)','^Hitachi','Hitachi',''],
['^Hoodisk','^Hoodisk','Hoodisk',''], ['^Hoodisk','^Hoodisk','Hoodisk',''],
['^(HP\b|MB0)','^HP','HP',''], # vb: VB0250EAVER but clashes with vbox; HP_SSD_S700_120G ['^(HP\b|MB0|GJ0)','^HP','HP',''], # vb: VB0250EAVER but clashes with vbox; HP_SSD_S700_120G
['^(LSD|Lexar|JumpDrive)','^Lexar','Lexar',''], # mmc-LEXAR_0xb016546c ['^(LSD|Lexar|JumpDrive)','^Lexar','Lexar',''], # mmc-LEXAR_0xb016546c
# OCZSSD2-2VTXE120G is OCZ-VERTEX2_3.5 # OCZSSD2-2VTXE120G is OCZ-VERTEX2_3.5
['^(OCZ|APOC|D2|DEN|DEN|DRSAK|EC188|FTNC|GFGC|MANG|MMOC|NIMC|NIMR|PSIR|TALOS2|TMSC|TRSAK)','^OCZ[\s\-]','OCZ',''], ['^(OCZ|APOC|D2|DEN|DEN|DRSAK|EC188|FTNC|GFGC|MANG|MMOC|NIMC|NIMR|PSIR|TALOS2|TMSC|TRSAK)','^OCZ[\s\-]','OCZ',''],
@ -8444,6 +8490,7 @@ sub device_vendor {
['^DREVO\b','^DREVO','Drevo',''], ['^DREVO\b','^DREVO','Drevo',''],
['^(Eaget|V8$)','^Eaget','Eaget',''], ['^(Eaget|V8$)','^Eaget','Eaget',''],
['^EXCELSTOR','^EXCELSTOR( TECHNO(LOGY)?)?','Excelstor',''], ['^EXCELSTOR','^EXCELSTOR( TECHNO(LOGY)?)?','Excelstor',''],
['^Fantom','^Fantom( Drive[s]?)?','Fantom Drives',''],
['^FASTDISK','^FASTDISK','FASTDISK',''], ['^FASTDISK','^FASTDISK','FASTDISK',''],
['^FORESEE','^FORESEE','Foresee',''], ['^FORESEE','^FORESEE','Foresee',''],
['^GALAX\b','^GALAX','GALAX',''], ['^GALAX\b','^GALAX','GALAX',''],
@ -8455,6 +8502,7 @@ sub device_vendor {
['^(G[\.]?SKILL)','^G[\.]?SKILL','G.SKILL',''], ['^(G[\.]?SKILL)','^G[\.]?SKILL','G.SKILL',''],
['^HUAWEI','^HUAWEI','Huawei',''], ['^HUAWEI','^HUAWEI','Huawei',''],
['^(IBM|DT)','^IBM','IBM',''], ['^(IBM|DT)','^IBM','IBM',''],
['^IEI Tech','^IEI Tech(\.|nology)?( Corp(\.|oration)?)?','IEI Technology',''],
['^Imation','^Imation(\sImation)?','Imation',''], # Imation_ImationFlashDrive; TF20 is imation/tdk ['^Imation','^Imation(\sImation)?','Imation',''], # Imation_ImationFlashDrive; TF20 is imation/tdk
['^(InnoDisk|Innolite)','^InnoDisk( Corp.)?','InnoDisk',''], ['^(InnoDisk|Innolite)','^InnoDisk( Corp.)?','InnoDisk',''],
['^Innostor','^Innostor','Innostor',''], ['^Innostor','^Innostor','Innostor',''],
@ -8463,6 +8511,7 @@ sub device_vendor {
['^Kingfast','^Kingfast','Kingfast',''], ['^Kingfast','^Kingfast','Kingfast',''],
['^KingMAX','^KingMAX','KingMAX',''], ['^KingMAX','^KingMAX','KingMAX',''],
['^KINGSHARE','^KINGSHARE','KingShare',''], ['^KINGSHARE','^KINGSHARE','KingShare',''],
['^KingSpec','^KingSpec','KingSpec',''],
['^(LITE[\-]?ON[\s\-]?IT)','^LITE[\-]?ON[\s\-]?IT','LITE-ON IT',''], # LITEONIT_LSS-24L6G ['^(LITE[\-]?ON[\s\-]?IT)','^LITE[\-]?ON[\s\-]?IT','LITE-ON IT',''], # LITEONIT_LSS-24L6G
['^(LITE[\-]?ON|PH6)','^LITE[\-]?ON','LITE-ON',''], # PH6-CE240-L ['^(LITE[\-]?ON|PH6)','^LITE[\-]?ON','LITE-ON',''], # PH6-CE240-L
['^M-Systems','^M-Systems','M-Systems',''], ['^M-Systems','^M-Systems','M-Systems',''],
@ -9249,8 +9298,8 @@ sub display_compositor {
# as of version 20 is wayland compositor # as of version 20 is wayland compositor
['enlightenment','enlightenment','','enlightenment'], ['enlightenment','enlightenment','','enlightenment'],
['gnome-shell','gnome-shell','','gnome-shell'], ['gnome-shell','gnome-shell','','gnome-shell'],
['kwin_wayland','kwin_wayland','','kwin wayland'], ['kwin_wayland','kwin_wayland','','kwin_wayland'],
['kwin_x11','kwin_x11','','kwin x11'], ['kwin_x11','kwin_x11','','kwin_x11'],
#['kwin','kwin','','kwin'], #['kwin','kwin','','kwin'],
['marco','marco','','marco'], ['marco','marco','','marco'],
['muffin','muffin','','muffin'], ['muffin','muffin','','muffin'],
@ -13735,6 +13784,7 @@ sub lm_sensors_data {
#my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-w-other-biker.txt"; #my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-w-other-biker.txt";
#my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-asus-chassis-1.txt"; #my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-asus-chassis-1.txt";
#my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-devnull-1.txt"; #my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-devnull-1.txt";
#my $file = "$ENV{'HOME'}/bin/scripts/inxi/data/sensors/sensors-jammin1.txt";
#@sensors_data = main::reader($file); #@sensors_data = main::reader($file);
# print join ("\n", @sensors_data), "\n"; # print join ("\n", @sensors_data), "\n";
@sensors_data = map {$_ =~ s/\s*:\s*\+?/:/;$_} @sensors_data; @sensors_data = map {$_ =~ s/\s*:\s*\+?/:/;$_} @sensors_data;
@ -13762,10 +13812,13 @@ sub lm_sensors_data {
# note that because of charset issues, no "°" degree sign used, but it is required # note that because of charset issues, no "°" degree sign used, but it is required
# in testing regex to avoid error. It might be because I got that data from a forum post, # in testing regex to avoid error. It might be because I got that data from a forum post,
# note directly via debugger. # note directly via debugger.
if ($_ =~ /^(AMBIENT|M\/B|MB|SIO|SYS).*:([0-9\.]+)[\s°]*(C|F)/i) { if ($_ =~ /^(AMBIENT|M\/B|MB|Motherboard|SIO|SYS).*:([0-9\.]+)[\s°]*(C|F)/i) {
$sensors{'mobo-temp'} = $2; # avoid SYSTIN: 118 C
$working_unit = $3; if (main::is_numeric($2) && $2 < 90 ){
$sensors{'temp-unit'} = set_temp_unit($sensors{'temp-unit'},$working_unit) if $working_unit; $sensors{'mobo-temp'} = $2;
$working_unit = $3;
$sensors{'temp-unit'} = set_temp_unit($sensors{'temp-unit'},$working_unit) if $working_unit;
}
} }
# issue 58 msi/asus show wrong for CPUTIN so overwrite it if PECI 0 is present # issue 58 msi/asus show wrong for CPUTIN so overwrite it if PECI 0 is present
# http://www.spinics.net/lists/lm-sensors/msg37308.html # http://www.spinics.net/lists/lm-sensors/msg37308.html
@ -13844,7 +13897,7 @@ sub lm_sensors_data {
$sensors{'fan-main'} = () if !$sensors{'fan-main'}; $sensors{'fan-main'} = () if !$sensors{'fan-main'};
$sensors{'fan-main'}[1] = $2; $sensors{'fan-main'}[1] = $2;
} }
elsif (!$sensors{'fan-main'}[2] && $_ =~ /^(M\/B|MB|SYS).*:([0-9]+)[\s]RPM/i) { elsif (!$sensors{'fan-main'}[2] && $_ =~ /^(M\/B|MB|SYS|Motherboard).*:([0-9]+)[\s]RPM/i) {
$sensors{'fan-main'} = () if !$sensors{'fan-main'}; $sensors{'fan-main'} = () if !$sensors{'fan-main'};
$sensors{'fan-main'}[2] = $2; $sensors{'fan-main'}[2] = $2;
} }
@ -14659,9 +14712,9 @@ sub usb_data {
#print "pt0:$protocol\n"; #print "pt0:$protocol\n";
@data = ({ @data = ({
main::key($num++,'Hub') => $bus_id, main::key($num++,'Hub') => $bus_id,
main::key($num++,'usb') => $speed, main::key($num++,'info') => $product,
main::key($num++,'type') => $product,
main::key($num++,'ports') => $ports, main::key($num++,'ports') => $ports,
main::key($num++,'usb') => $speed,
},); },);
@rows = (@rows,@data); @rows = (@rows,@data);
$b_hub = 1; $b_hub = 1;
@ -14673,23 +14726,21 @@ sub usb_data {
$type ||= 'N/A'; $type ||= 'N/A';
$driver ||= 'N/A'; $driver ||= 'N/A';
#print "pt3:$class:$product\n"; #print "pt3:$class:$product\n";
$rows[$j]{main::key($num++,'Device')} = $product; $rows[$j]{main::key($num++,'Device')} = $bus_id;
if ($extra > 1){ $rows[$j]{main::key($num++,'info')} = $product;
$rows[$j]{main::key($num++,'type')} = $type;
if ($extra > 0){
$rows[$j]{main::key($num++,'driver')} = $driver; $rows[$j]{main::key($num++,'driver')} = $driver;
} }
if ($extra > 0){ if ($extra > 2 && $id[9]){
$rows[$j]{main::key($num++,'usb')} = $speed; $rows[$j]{main::key($num++,'interfaces')} = $id[9];
} }
$rows[$j]{main::key($num++,'type')} = $type; $rows[$j]{main::key($num++,'usb')} = $speed;
$rows[$j]{main::key($num++,'bus ID')} = $bus_id;
} }
if ($extra > 1){ if ($extra > 1){
$rows[$j]{main::key($num++,'chip ID')} = $chip_id; $rows[$j]{main::key($num++,'chip ID')} = $chip_id;
} }
if (!$b_hub && $extra > 2){ if (!$b_hub && $extra > 2){
if ($id[9]){
$rows[$j]{main::key($num++,'interfaces')} = $id[9];
}
if ($serial){ if ($serial){
$rows[$j]{main::key($num++,'serial')} = main::apply_filter($serial); $rows[$j]{main::key($num++,'serial')} = main::apply_filter($serial);
} }
@ -15763,13 +15814,15 @@ sub get_wm_version {
# } # }
sub set_info_data { sub set_info_data {
eval $start if $b_log; eval $start if $b_log;
main::set_ps_gui() if ! $b_ps_gui;
my (@data,@info,$item); my (@data,@info,$item);
my $pattern = 'alltray|awn|bar|bmpanel|bmpanel2|budgie-panel|cairo-dock|'; my $pattern = 'alltray|awn|bar|bmpanel|bmpanel2|budgie-panel|cairo-dock|';
$pattern .= 'dde-dock|dmenu|dockbarx|docker|docky|dzen|dzen2|'; $pattern .= 'dde-dock|dmenu|dockbarx|docker|docky|dzen|dzen2|';
$pattern .= 'fbpanel|fspanel|glx-dock|gnome-panel|hpanel|i3bar|icewmtray|'; $pattern .= 'fbpanel|fspanel|glx-dock|gnome-panel|hpanel|i3bar|icewmtray|';
$pattern .= 'kdocker|kicker|'; $pattern .= 'kdocker|kicker|';
$pattern .= 'latte|lemonbar|ltpanel|lxpanel|lxqt-panel|matchbox-panel|mate-panel|'; $pattern .= 'latte|latte-dock|lemonbar|ltpanel|lxpanel|lxqt-panel|';
$pattern .= 'ourico|perlpanel|plank|plasma-desktop|plasma-netbook|polybar|pypanel|'; $pattern .= 'matchbox-panel|mate-panel|ourico|';
$pattern .= 'perlpanel|plank|plasma-desktop|plasma-netbook|polybar|pypanel|';
$pattern .= 'razor-panel|razorqt-panel|stalonetray|taskbar|tint2|trayer|'; $pattern .= 'razor-panel|razorqt-panel|stalonetray|taskbar|tint2|trayer|';
$pattern .= 'vala-panel|wbar|wharf|wingpanel|witray|'; $pattern .= 'vala-panel|wbar|wharf|wingpanel|witray|';
$pattern .= 'xfce4-panel|xfce5-panel|xmobar|yabar'; $pattern .= 'xfce4-panel|xfce5-panel|xmobar|yabar';
@ -16090,12 +16143,15 @@ sub get_linux_distro {
} }
} }
if ($extra > 0){ if ($extra > 0){
my $base_debian_version_distro = 'sidux';
my $base_debian_version_osr = 'lmde|neptune|pureos|sparky|tails';
my $base_default = 'antix-version|mx-version'; # osr has base ids my $base_default = 'antix-version|mx-version'; # osr has base ids
my $base_issue = 'bunsen'; # base only found in issue my $base_issue = 'bunsen'; # base only found in issue
my $base_manual = 'blankon|deepin|kali'; # synthesize, no direct data available my $base_manual = 'blankon|deepin|kali'; # synthesize, no direct data available
my $base_osr = 'aptosid|grml|siduction|bodhi'; # osr base, distro id in list of distro files my $base_osr = 'aptosid|grml|siduction|bodhi'; # osr base, distro id in list of distro files
my $base_osr_issue = 'grml|linux lite'; # osr base, distro id in issue my $base_osr_issue = 'grml|linux lite'; # osr base, distro id in issue
my $base_osr_ubuntu = 'mint|neon|zorin'; # osr has distro name but has ubuntu ID_LIKE/UBUNTU_CODENAME # osr has distro name but has ubuntu ID_LIKE/UBUNTU_CODENAME
my $base_osr_ubuntu = 'mint|neon|nitrux|zorin';
my $base_upstream_lsb = '/etc/upstream-release/lsb-release'; my $base_upstream_lsb = '/etc/upstream-release/lsb-release';
my $base_upstream_osr = '/etc/upstream-release/os-release'; my $base_upstream_osr = '/etc/upstream-release/os-release';
# first: try, some distros have upstream-release, elementary, new mint # first: try, some distros have upstream-release, elementary, new mint
@ -16123,11 +16179,15 @@ sub get_linux_distro {
elsif ( @distro_files && (grep {/($base_default)/} @distro_files) ){ elsif ( @distro_files && (grep {/($base_default)/} @distro_files) ){
$base_type = 'default'; $base_type = 'default';
} }
# must go before base_osr_ubuntu test
elsif ( grep {/($base_debian_version_osr)/i} @osr ){
$system_base = debian_id();
}
elsif ( grep {/($base_osr_ubuntu)/} @osr ){ elsif ( grep {/($base_osr_ubuntu)/} @osr ){
$base_type = 'ubuntu'; $base_type = 'ubuntu';
} }
elsif ( ( ($distro_id && $distro_id =~ /($base_osr_issue)/ ) || elsif ( ( ($distro_id && $distro_id =~ /($base_osr_issue)/ ) ||
(@distro_files && (grep {/($base_osr)/} @distro_files)) ) && (@distro_files && (grep {/($base_osr)/} @distro_files) ) ) &&
!(grep {/($base_osr)/i} @osr)){ !(grep {/($base_osr)/i} @osr)){
$system_base = get_os_release(); $system_base = get_os_release();
} }
@ -16135,6 +16195,9 @@ sub get_linux_distro {
$system_base = get_os_release($base_type); $system_base = get_os_release($base_type);
} }
} }
if (!$system_base && @distro_files && ( grep {/($base_debian_version_distro)/i} @distro_files ) ){
$system_base = debian_id();
}
if (!$system_base && $lc_issue && $lc_issue =~ /($base_manual)/){ if (!$system_base && $lc_issue && $lc_issue =~ /($base_manual)/){
my $id = $1; my $id = $1;
my %manual = ( my %manual = (
@ -16246,6 +16309,9 @@ sub get_os_release {
elsif ($base_type eq 'ubuntu' && $working[0] eq 'UBUNTU_CODENAME' && $working[1]){ elsif ($base_type eq 'ubuntu' && $working[0] eq 'UBUNTU_CODENAME' && $working[1]){
$base_version = ucfirst($working[1]); $base_version = ucfirst($working[1]);
} }
elsif ($base_type eq 'debian' && $working[0] eq 'DEBIAN_CODENAME' && $working[1]){
$base_version = $working[1];
}
} }
} }
# NOTE: tumbleweed has pretty name but pretty name does not have version id # NOTE: tumbleweed has pretty name but pretty name does not have version id
@ -16282,14 +16348,53 @@ sub get_os_release {
elsif ($base_type eq 'default' && ($pretty_name || ($name && $version_name) ) ){ elsif ($base_type eq 'default' && ($pretty_name || ($name && $version_name) ) ){
$distro = ($name && $version_name) ? "$name $version_name" : $pretty_name; $distro = ($name && $version_name) ? "$name $version_name" : $pretty_name;
} }
# LMDE has only limited data in os-release, no _LIKE values # LMDE 2 has only limited data in os-release, no _LIKE values. 3 has like and debian_codename
elsif ( $base_type eq 'ubuntu' && $lc_name =~ /^(debian|ubuntu)/ && ($pretty_name || ($name && $version_name))){ elsif ( $base_type eq 'ubuntu' && $lc_name =~ /^(debian|ubuntu)/ && ($pretty_name || ($name && $version_name))){
$distro = ($name && $version_name) ? "$name $version_name": $pretty_name; $distro = ($name && $version_name) ? "$name $version_name": $pretty_name;
} }
elsif ( $base_type eq 'debian' && $base_version ){
$distro = debian_id($base_version);
}
} }
eval $end if $b_log; eval $end if $b_log;
return $distro; return $distro;
} }
# arg: 1 - optional: debian codename
sub debian_id {
eval $start if $b_log;
my ($codename) = @_;
my ($debian_version,$id);
$debian_version = (main::reader('/etc/debian_version','strip'))[0] if -r '/etc/debian_version';
$id = 'Debian';
return if !$debian_version && !$codename;
# note, 3.0, woody, 3.1, sarge, but after it's integer per version
my %debians = (
'4' => 'etch',
'5' => 'lenny',
'6' => 'squeeze',
'7' => 'wheezy',
'8' => 'jessie',
'9' => 'stretch',
'10' => 'buster',
'11' => 'bullseye',
'12' => 'bookworm', # ?
);
if (main::is_numeric($debian_version)){
$id .= " $debian_version $debians{int($debian_version)}";
}
elsif ($codename) {
my %by_value = reverse %debians;
my $version = (main::is_numeric($debian_version)) ? "$debian_version $codename": $debian_version;
$id .= " $version";
}
# like buster/sid
elsif ($debian_version) {
$id .= " $debian_version";
}
eval $end if $b_log;
return $id;
}
# note, these are only for matching derived names, no need to go # note, these are only for matching derived names, no need to go
# all the way back here, update as new names are known. This is because # all the way back here, update as new names are known. This is because
# Mint is using UBUNTU_CODENAME without ID data. # Mint is using UBUNTU_CODENAME without ID data.
@ -17636,7 +17741,7 @@ sub set_ps_gui {
@temp=qw(alltray awn bar bmpanel bmpanel2 budgie-panel @temp=qw(alltray awn bar bmpanel bmpanel2 budgie-panel
cairo-dock dde-dock dmenu dockbarx docker docky dzen dzen2 cairo-dock dde-dock dmenu dockbarx docker docky dzen dzen2
fbpanel fspanel glx-dock gnome-panel hpanel i3bar icewmtray fbpanel fspanel glx-dock gnome-panel hpanel i3bar icewmtray
kdocker kicker latte lemonbar ltpanel lxpanel lxqt-panel kdocker kicker latte latte-dock lemonbar ltpanel lxpanel lxqt-panel
matchbox-panel mate-panel ourico matchbox-panel mate-panel ourico
perlpanel plank plasma-desktop plasma-netbook polybar pypanel perlpanel plank plasma-desktop plasma-netbook polybar pypanel
razor-panel razorqt-panel stalonetray taskbar tint2 trayer vala-panel razor-panel razorqt-panel stalonetray taskbar tint2 trayer vala-panel

28
inxi.1
View file

@ -1,4 +1,4 @@
.TH INXI 1 "2018\-08\-28" inxi "inxi manual" .TH INXI 1 "2018\-09\-07" inxi "inxi manual"
.SH NAME .SH NAME
inxi \- Command line system information script for console and IRC inxi \- Command line system information script for console and IRC
.SH SYNOPSIS .SH SYNOPSIS
@ -93,6 +93,10 @@ Set color scheme. If no scheme number is supplied, 0 is assumed.
These color selectors run a color selector option prior to inxi starting which lets These color selectors run a color selector option prior to inxi starting which lets
you set the config file value for the selection. you set the config file value for the selection.
NOTE: All configuration file set color values are removed when output is
piped or redirected. You must use the explicit runtime \fB\-c <color number>\fR option
if you want color codes to be present in the piped/redirected output.
Color selectors for each type display (NOTE: IRC and global only show safe color set): Color selectors for each type display (NOTE: IRC and global only show safe color set):
.TP .TP
.B \-c 94\fR .B \-c 94\fR
@ -298,6 +302,8 @@ APT distros like PCLinuxOS or Alt-Linux)
\fBSLACKPKG\fR (Slackware + derived versions) \fBSLACKPKG\fR (Slackware + derived versions)
\fBTCE\fR (TinyCore)
\fBURPMQ\fR (Mandriva, Mageia + derived versions) \fBURPMQ\fR (Mandriva, Mageia + derived versions)
\fBYUM/ZYPP\fR (Fedora, Red Hat, Suse + derived versions) \fBYUM/ZYPP\fR (Fedora, Red Hat, Suse + derived versions)
@ -365,6 +371,8 @@ Show USB data for attached Hubs and Devices. Hubs also show number of ports.
Be aware that a port is not always external, some may be internal, and either Be aware that a port is not always external, some may be internal, and either
used or unused (for example, a motherboard USB header connector that is not used). used or unused (for example, a motherboard USB header connector that is not used).
Hubs and Devices are listed in order of BusID.
BusID is generally in this format: BusID-port[.port][.port]:DeviceID BusID is generally in this format: BusID-port[.port][.port]:DeviceID
Device ID is a number created by the kernel, and has no necessary ordering Device ID is a number created by the kernel, and has no necessary ordering
@ -372,7 +380,7 @@ or sequence connection, but can be used to match this output to lsusb
values, which generally shows BusID / DeviceID (except for tree view, which values, which generally shows BusID / DeviceID (except for tree view, which
shows ports). shows ports).
Examples: \fRBus ID: 4-3.2.1:2\fR or \fRHub: 4-0:1\fR Examples: \fRDevice-3: 4-3.2.1:2\fR or \fRHub: 4-0:1\fR
.TP .TP
.B \-u\fR,\fB \-\-uuid\fR .B \-u\fR,\fB \-\-uuid\fR
@ -435,7 +443,8 @@ optical drive data (\fB\-d\fR), USB (\fB\-\-usb\fR); triggers \fB\-xx\fR extra d
.TP .TP
.B \-v 8 .B \-v 8
\- All system data available. Adds Repos (\fB\-r\fR), PCI slots (\fB\-\-slots\fR), processes \- All system data available. Adds Repos (\fB\-r\fR), PCI slots (\fB\-\-slots\fR), processes
(\fB\-tcm\fR). Useful for testing output and to see what data you can get from your system. (\fB\-tcm\fR), admin (\fB\-\-admin\fR). Useful for testing output and to see what data
you can get from your system.
.TP .TP
.B \-w\fR,\fB \-\-weather\fR .B \-w\fR,\fB \-\-weather\fR
Adds weather line. Note, this depends on an unreliable API so it may not always Adds weather line. Note, this depends on an unreliable API so it may not always
@ -602,7 +611,7 @@ methods are found for each distribution system base detection.
(\fB\-xt m\fR). (\fB\-xt m\fR).
.TP .TP
.B \-x \-\-usb\fR .B \-x \-\-usb\fR
\- For \fBDevices\fR, adds USB version/speed. \- For Devices, adds driver(s).
.TP .TP
.B \-x \-w\fR,\fB \-W\fR .B \-x \-w\fR,\fB \-W\fR
\- Adds humidity and barometric pressure. \- Adds humidity and barometric pressure.
@ -713,8 +722,6 @@ if \fBps\fR tests fail to find data.
.TP .TP
.B \-xx \-\-usb\fR .B \-xx \-\-usb\fR
\- Adds vendor:chip id. \- Adds vendor:chip id.
\- Adds driver(s).
.TP .TP
.B \-xx \-w\fR,\fB \-W\fR .B \-xx \-w\fR,\fB \-W\fR
\- Adds wind chill, heat index, and dew point if any of these are available. \- Adds wind chill, heat index, and dew point if any of these are available.
@ -813,7 +820,9 @@ Format is \fBhexadecimal (decimal)\fR if greater than 9, otherwise \fBhexadecima
\- Adds CPU microcode. Format is \fBhexadecimal\fR. \- Adds CPU microcode. Format is \fBhexadecimal\fR.
\- Adds CPU Errata (bugs) as known by your current kernel. \- Adds CPU Vulnerabilities (bugs) as known by your current kernel. Lists by
\fBType: ... (status|mitigation): ....\fR for systems that support this feature
(Linux kernel 4.14 or newer, or patched older kernels).
.SH ADVANCED OPTIONS .SH ADVANCED OPTIONS
@ -1120,6 +1129,11 @@ or conflicting items, but if you prefer to create your own configuration files,
here are the options. All take the integer value from the options available in here are the options. All take the integer value from the options available in
\fB\-c 94\-99\fR. \fB\-c 94\-99\fR.
NOTE: All default and configuration file set color values are removed when output is
piped or redirected. You must use the explicit \fB\-c <color number>\fR option
if you want colors to be present in the piped/redirected output (creating a PDF for
example).
\fBCONSOLE_COLOR_SCHEME\fR The color scheme for console output (not in X/Wayland). \fBCONSOLE_COLOR_SCHEME\fR The color scheme for console output (not in X/Wayland).
\fBGLOBAL_COLOR_SCHEME\fR Overrides all other color schemes. \fBGLOBAL_COLOR_SCHEME\fR Overrides all other color schemes.

View file

@ -1,3 +1,131 @@
=====================================================================================
Version: 3.0.23
Patch Version: 00
Script Date: 2018-09-07
-----------------------------------
Changes:
-----------------------------------
New version, man page. Fixes, enhancements, changes.
Thanks:
1. AntiX forums, for testing -C --admin, suggestions, always helpful.
Bugs:
1. Added switch to set @ps_gui, I forgot case where info block was only thing
that used ps_gui (Nitrux kde nomad latte case). This led to no info: data if
other ps_gui switches not activated. Now each block that can use it activates it.
Fixes:
1. To clarify issue #161 added help/man explanation on how to get colors in cases
where you want to preserve colors for piped or redirected output. Thanks fugo.
2. LMDE 3.0 released, slightly different system base handling, so refactored to
add Debian version, see enhancement 2. Tested on some old vm instances, improved
old system Debian system base id, but it's empirical, distro by distro, there is
no rule I can use to automatically do it, sadly.
3. 'Motherboard' sensors field name added, a few small tweaks to sensors. This
was in response to issue #159, which also raised a problem I was not really
aware of, user generated sensor config files, that can have totally random
field names. Longer term solution, start getting data from sys to pad out
lm-sensors data, or to handle cases where no lm-sensors installed.
4. Fixed kwin_11 and kwin_wayland compositor print names, I'd left out the _,
which made it look strange, like there were two compositors or something.
5. Fixed latte-dock ID, I thought the program name when running was latte, not
latte-dock. inxi checks for both now. Thanks Nitrux for exposing that in vm test.
6. Sensors: added in a small filter to motherboard temp, avoid values that are
too high, like SYSTIN: 118 C, filters out to only use < 90 C. Very unlikely a
mobo would be more than 90C unless it's a mistake or about to melt. This may
correct anoymous debugger dataset report from rakasunka.
Enhancements:
1. Added --admin to -v 8 and to --debugger 2x
2. Expanded system base to use Debian version tool, like the ubuntu one, that
lets me match version number to codename. The ubuntu one matches code names to
release dates. Added Neptune, PureOS, Sparky, Tails, to new Debian system base
handler.
3. Big enhancement: --admin -C now shows a nice report on cpu vulnerabilities,
and has a good error message if no data found. Report shows:
Vulnerabilities: Type: [e.g. meltdown] status/mitigation: text explanation.
Note: 'status' is for when no mitigation, either not applicable, or is vulnerable.
'mitigation' is when it's handled, and how. Thanks issue #160 Vascom from Fedora
for that request.
4. The never-ending saga of disk vendor IDs continues. More obscure vendors,
more matches to existing vendors. Thanks linuxlite/linux hardware database
Changes:
1. Reordered usb output, I don't know why I had Hubs and Devices use different
ordering and different -x switch priorities, that was silly, and made it hard to
read.
Now shows:
Device/Hub: bus-id-port-id[.port-id]:device-id info: [product info]
type/ports: [devices/hubs] usb: [type, speed]
-x adds drivers for devices, and usb: speed is now default for devices, same as
Hubs. Why I had those different is beyond me.
The USB ordering is now more sensible, the various components of each
matching whether hub or device.
Unfixable or Won't Fix:
1. Unable to detect Nomad desktop. As far as I can tell, Nomad is only a theme
applied to KDE Plasma, there is no program by that name detectable, only a
reference in ps aux to a theme called nomad.
2. Nitrux system base ID will not work until they correct their /etc/os-release file.
3. Tails live cd for some inexplicable reason uses non standard /etc/os-release
field names, which forces me to either do a custom detection just for them, or for
them to fix this bug. I opted for ignoring it, if I let each distro break standard
formats then try to work around it, the distro ID will grow to be a 1000 lines long
easily. Will file distro bug reports when I find these from now on.
Samples:
This shows the corrected, cleaned up, consistent usb output:
inxi -y80 --usb
USB:
Hub: 1-0:1 info: Full speed (or root) Hub ports: 14 usb: 2.0
Hub: 1-3:2 info: Atmel 4-Port Hub ports: 4 usb: 1.1
Device-1: 1-3.2:4 info: C-Media Audio Adapter (Planet UP-100 Genius G-Talk)
type: Audio,HID usb: 1.1
Device-2: 1-4:3 info: Wacom Graphire 2 4x5 type: Mouse usb: 1.1
Device-3: 1-10:5 info: Tangtop HID Keyboard type: Keyboard,Mouse usb: 1.1
Device-4: 1-13:7 info: Canon CanoScan LiDE 110 type: <vendor specific>
usb: 2.0
Device-5: 1-14:8 info: Apple Ethernet Adapter [A1277] type: Network usb: 2.0
Hub: 2-0:1 info: Full speed (or root) Hub ports: 8 usb: 3.1
Hub: 3-0:1 info: Full speed (or root) Hub ports: 2 usb: 2.0
Hub: 4-0:1 info: Full speed (or root) Hub ports: 2 usb: 3.1
Hub: 5-0:1 info: Full speed (or root) Hub ports: 4 usb: 2.0
Hub: 6-0:1 info: Full speed (or root) Hub ports: 4 usb: 3.0
inxi -y80 --usb -xxxz
USB:
Hub: 1-0:1 info: Full speed (or root) Hub ports: 14 usb: 2.0
chip ID: 1d6b:0002
Hub: 1-3:2 info: Atmel 4-Port Hub ports: 4 usb: 1.1 chip ID: 03eb:0902
Device-1: 1-3.2:4 info: C-Media Audio Adapter (Planet UP-100 Genius G-Talk)
type: Audio,HID driver: cm109,snd-usb-audio interfaces: 4 usb: 1.1
chip ID: 0d8c:000e
Device-2: 1-4:3 info: Wacom Graphire 2 4x5 type: Mouse driver: usbhid,wacom
interfaces: 1 usb: 1.1 chip ID: 056a:0011
Device-3: 1-10:5 info: Tangtop HID Keyboard type: Keyboard,Mouse
driver: hid-generic,usbhid interfaces: 2 usb: 1.1 chip ID: 0d3d:0001
Device-4: 1-13:7 info: Canon CanoScan LiDE 110 type: <vendor specific>
driver: N/A interfaces: 1 usb: 2.0 chip ID: 04a9:1909
Device-5: 1-14:8 info: Apple Ethernet Adapter [A1277] type: Network
driver: asix interfaces: 1 usb: 2.0 chip ID: 05ac:1402 serial: <filter>
Hub: 2-0:1 info: Full speed (or root) Hub ports: 8 usb: 3.1
chip ID: 1d6b:0003
Hub: 3-0:1 info: Full speed (or root) Hub ports: 2 usb: 2.0
chip ID: 1d6b:0002
Hub: 4-0:1 info: Full speed (or root) Hub ports: 2 usb: 3.1
chip ID: 1d6b:0003
Hub: 5-0:1 info: Full speed (or root) Hub ports: 4 usb: 2.0
chip ID: 1d6b:0002
Hub: 6-0:1 info: Full speed (or root) Hub ports: 4 usb: 3.0
chip ID: 1d6b:0003
-----------------------------------
-- Harald Hope - Fri, 07 Sep 2018 13:01:40 -0700
===================================================================================== =====================================================================================
Version: 3.0.22 Version: 3.0.22
Patch Version: 00 Patch Version: 00