App-GitHooks
view release on metacpan or search on metacpan
bin/githooks view on Meta::CPAN
#!/usr/bin/env perl
use strict;
use warnings;
# External dependencies.
use App::GitHooks;
use Cwd qw();
use Data::Dumper;
use Data::Section -setup;
use File::Spec;
use Getopt::Long;
use Git::Repository;
use Pod::Usage qw();
use Try::Tiny;
use autodie;
=head1 NAME
githooks - Setup utility for App::GitHooks
=head1 VERSION
Version 1.9.0
=head1 DESCRIPTION
This command line utility allows setting up git hooks in the current git
repository, so that all of App::GitHooks' hooks are triggered properly.
=head1 SYNOPSIS
githooks <command>
=head1 COMMANDS
=over 4
=item * C<help> - Show the commands available.
=item * C<install> - Install all the git hooks for the current repository.
=item * C<list> - List the plugins currently installed.
=item * C<uninstall> - Remove all the git hooks for the current repository.
=item * C<version> - Display the version of App::GitHooks in use.
=back
=head1 OPTIONS
=over 4
=item * C<--chmod> - Chmod to use for the git hooks (default: 755).
=back
=cut
# Parse the action.
my $action = shift( @ARGV );
usage()
if !defined( $action ) || $action eq '';
# Parse command-line options.
my $chmod = '0755';
Getopt::Long::GetOptions(
'chmod' => \$chmod,
( run in 2.282 seconds using v1.01-cache-2.11-cpan-99c4e6809bf )