Skip to content

mkmotd: fix HP EliteDesk #68

Merged
merged 1 commit into from
Jan 22, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions mkmotd/mkmotd.pl
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ sub policy { # policy('theinternet') --> ('zeile1,'zeile2',....)
my @pc=`cat /proc/cpuinfo`;
my $mn='unknown CPU';
$T{NCPU} = grep {/model name/ and $mn = $_; /processor/} @pc;
$mn =~ s/\(.*?\)|\d+-Core Processor|xeon|Virtual|Athlon|model name\s*:|six.core|quad.core|dual.core|intel|Processor|cpu|core//ig;
$mn =~ s/\(.*?\)|\d+-Core Processor|xeon|Virtual|Athlon|model name\s*:|six.core|quad.core|dual.core|intel|Processor|cpu|core| with Radeon Vega Graphics//ig;
$mn =~ s/\s(E\d\-)\s/$1/;
$mn =~ s/\s\d\s\@/ \@/;
$mn =~ s/version\s+/v/g;
Expand Down Expand Up @@ -155,12 +155,12 @@ sub policy { # policy('theinternet') --> ('zeile1,'zeile2',....)
($pn ne '') and $pn = " $pn";
$T{SYSTEM} = "$mf$pn";
$T{SYSTEM} =~ s/_/ /g;
$T{SYSTEM} =~ s{( WorkStation| Transport| Tower|Hewlett-Packard |/S2932-E/S2932-SI| Thunder| Computer Corp|Technology Co., Ltd. | Standard PC)}{}i;
$T{SYSTEM} =~ s{(^HP | WorkStation| Transport| Tower|Hewlett-Packard |/S2932-E/S2932-SI| Thunder| Computer Corp|Technology Co., Ltd. | Standard PC)}{}i;
}

my %BC = (
'bugblatterbeastoftraal' => 'TYAN VX50 B4985',
'crap03' => 'TYAN GT20-B2925/B2925-E',
# 'crap03' => 'TYAN GT20-B2925/B2925-E',
'keineahnung' => 'FUJITSU ESPRIMO P756',
'furunkel' => 'HP Z200 Workstation',
);
Expand Down