script/grimlock_deploy_schema.pl untested

filter: Statementstmt 0.0% 0 / 37 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 11 Podpod 0.0% 0 / 4 totaltotal 0.0% 0 / 54 CC 1 SCAR 6.9
CC
1
Cov
0%
install
2.0
upgrade
2.0
current_version
2.0
CRAP 2.0
1 #!/usr/bin/env perl
2
3 use strict;
4 use warnings;
5
6 use feature ":5.10";
7
8 use FindBin;
9 use lib "$FindBin::Bin/../lib";
10 use Grimlock::Schema;
11 use Config::JFDI;
12
13 my $config = Config::JFDI->new( name =>'Grimlock::Web' );
14 my $config_hash = $config->get;
15 my $connect_info = $config_hash->{"Model::Database"}{"connect_info"};
16 my $schema = Grimlock::Schema->connect($connect_info);
17
18 sub install {
19 $schema->deploy;
20 }
21
22 sub upgrade {
23 say "work in progress";
24 }
25
26 sub current_version {
27 say "work in progress"
28 }
29
30 sub help {
31 say <<'OUT';
32 usage:
33 install
34 upgrade
35 current-version
36 OUT
37 }
38
39 help unless $ARGV[0];
40
41 given ( $ARGV[0] ) {
42 when ('install') { install() }
43 when ('upgrade') { upgrade() }
44 when ('current-version') { current_version() }
45 }
46  
47  
48 =head1 NAME
49 grimlock_deploy_schema.pl - MAKE DATABASE FOR GRIMLOCK BLOG
50  
51 =head1 SYNOPSIS
52  
53 grimlock_deploy_schema.pl install
54  
55 =head1 DESCRIPTION
56  
57 MAKE DATABASE FOR GRIMLOCK BLOG SO IT CAN SAVE BLOGS ABOUT CESIUM SALAMI AND BERYLLIUM BALONEY
58  
59 =head1 AUTHORS
60  
61 ME, GRIMLOCK!
62  
63 =head1 COPYRIGHT
64  
65 ME GRIMLOCK WANT SHARE BEAUTIFUL SOFTWARE ME WRITE WITH WORLD. ME GRIMLOCK SAY THIS SOFTWARE RELEASE UNDER ARTISTIC LICENSE.
66  
67 SEE L<perlartistic>.
68  
69 =cut
70