summaryrefslogtreecommitdiff
path: root/lib/Loadbars/Shared.pm
blob: 0f02b7ed97437bebeefa732b7d5c3a92a2359a49 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
package Loadbars::Shared;

use Exporter;

use base 'Exporter';

our @EXPORT = qw(
  %PIDS
  %AVGSTATS
  %CPUSTATS
  %MEMSTATS
  %MEMSTATS_HAS
  %C
  %I
);

our %PIDS : shared;
our %AVGSTATS : shared;
our %CPUSTATS : shared;
our %MEMSTATS : shared;
our %MEMSTATS_HAS : shared;

#my %NETSTATS : shared;
#my %NETSTATS_HAS : shared;

# Global configuration hash
our %C : shared;

# Global configuration hash for internal settings (not configurable)
our %I : shared;

# Setting defaults
%C = (
    average      => 15,
    barwidth     => 35,
    extended     => 0,
    factor       => 1,
    height       => 230,
    maxwidth     => 1280,
    samples      => 1000,
    showcores    => 0,
    showmem      => 0,
    showtext     => 1,
    showtexthost => 0,
    sshopts      => '',
);

%I = (
    cpuregexp   => 'cpu',
    showtextoff => 0,
);