gitprep / script / gitprep /
Newer Older
23 lines | 0.633kb
copy gitweblite soruce code
root authored on 2012-11-23
1
#!/usr/bin/env perl
2
use Mojo::Base -strict;
3

            
4
use File::Basename 'dirname';
5
use File::Spec::Functions qw/catdir splitdir/;
6

            
7
# Source directory has precedence
8
my @base = (splitdir(dirname(__FILE__)), '..');
9
my $lib = join('/', @base, 'lib');
10
-e catdir(@base, 't') ? unshift(@INC, $lib) : push(@INC, $lib);
11

            
12
# Check if Mojolicious is installed;
13
die <<EOF unless eval 'use Mojolicious::Commands; 1';
14
It looks like you don't have the Mojolicious framework installed.
15
Please visit http://mojolicio.us for detailed installation instructions.
16

            
17
EOF
18

            
19
# Application
renamed gitpub to gitprep
Yuki Kimoto authored on 2012-11-26
20
$ENV{MOJO_APP} ||= 'Gitprep';
copy gitweblite soruce code
root authored on 2012-11-23
21

            
22
# Start commands
23
Mojolicious::Commands->start;