summaryrefslogtreecommitdiff
path: root/lib/Loadbars/Shared.pm
blob: 01dc9fc4c14fa2c3ba4798088dca14d193c15982 (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
53
54
55
56
57
58
59
60
61
62
package Loadbars::Shared;

use Exporter;

use base 'Exporter';

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

our %PIDS : shared;

our %CPUSTATS : shared;
our %AVGSTATS : shared;
our %AVGSTATS_HAS : shared;

our %MEMSTATS : shared;
our %MEMSTATS_HAS : shared;

our %NETSTATS : shared;
our %NETSTATS_HAS : shared;
our %NETSTATS_INT : shared;

# Global configuration hash
our %C : shared;

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

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

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