line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package EPublisher::Config; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
# ABSTRACT: Config module for EPublisher |
4
|
8
|
|
|
8
|
|
67292
|
use strict; |
|
8
|
|
|
|
|
26
|
|
|
8
|
|
|
|
|
216
|
|
5
|
8
|
|
|
8
|
|
38
|
use warnings; |
|
8
|
|
|
|
|
17
|
|
|
8
|
|
|
|
|
179
|
|
6
|
8
|
|
|
8
|
|
37
|
use Carp; |
|
8
|
|
|
|
|
13
|
|
|
8
|
|
|
|
|
426
|
|
7
|
8
|
|
|
8
|
|
4520
|
use YAML::Tiny; |
|
8
|
|
|
|
|
44802
|
|
|
8
|
|
|
|
|
1059
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
our $VERSION = 0.01; |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub get_config{ |
12
|
6
|
|
|
6
|
1
|
2208
|
my ($class,$file) = @_; |
13
|
|
|
|
|
|
|
|
14
|
6
|
100
|
100
|
|
|
478
|
croak "No (existant) config file given!" unless defined $file and -e $file; |
15
|
4
|
|
|
|
|
27
|
my $config = YAML::Tiny->read( $file )->[0]; |
16
|
|
|
|
|
|
|
|
17
|
4
|
|
|
|
|
26959
|
return $config; |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
1; |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
__END__ |