source: ocsinventory-agent/trunk/fuentes/lib/Ocsinventory/Agent/Backend/OS/Generic/Lspci/Modems.pm @ 468

Last change on this file since 468 was 468, checked in by mabarracus, 4 years ago

Copyt trusty code

File size: 371 bytes
Line 
1package Ocsinventory::Agent::Backend::OS::Generic::Lspci::Modems;
2use strict;
3
4sub run {
5  my $params = shift;
6  my $common = $params->{common};
7
8  foreach(`lspci`){
9
10    if(/modem/i && /\d+\s(.+):\s*(.+)$/){
11      my $name = $1;
12      my $description = $2;
13
14
15      $common->addModems({
16          'DESCRIPTION'  => $description,
17          'NAME'          => $name,
18        });
19    }
20  }
21}
22
231
Note: See TracBrowser for help on using the repository browser.