1 package Gitalist::ScriptRole;
3 use MooseX::Types::Common::String qw/NonEmptySimpleStr/;
4 use namespace::autoclean;
7 isa => NonEmptySimpleStr, is => 'ro',
8 predicate => 'has_repo_dir'
13 if ($self->has_repo_dir) {
14 # FIXME - This seems gross. I should be able to pass things through
15 # to the app instance, but the params are sent to the engine
16 # and not actually used to construct the app.. Not that
17 # $ENV{GITLIST_REPO_DIR} is a bad move, just that that being
18 # the mechanism by which this works that is non optimum.
19 $ENV{GITALIST_REPO_DIR} = $self->repo_dir;
27 Gitalist::ScriptRole - Role for Gitalist scripts.
31 Wraps the run method in Catalyst scripts to apply the C<< --repo_dir >>
36 See L<Gitalist> for authors.
40 See L<Gitalist> for the license.