} else {
return unless -x $git;
}
+ $git = abs_path $git unless file_name_is_absolute $git;
my $conf = 'App::Rgit::Config::Default';
eval "require $conf; 1" or Carp::confess("Couldn't load $conf: $@");
use warnings;
use Cwd qw/cwd abs_path/;
-use File::Spec::Functions qw/catdir catfile/;
+use File::Spec::Functions qw/curdir catdir catfile/;
use File::Temp qw/tempfile tempdir/;
use Test::More;
);
my $ar = App::Rgit->new(
- git => abs_path('t/bin/git'),
+ git => catfile(curdir, qw/t bin git/),
root => $tmpdir,
cmd => $cmd,
args => [ abs_path($filename), $cmd, qw/%n %g %w %b %G %W %B %R %%n %x/ ],
use strict;
use warnings;
-use Cwd qw/abs_path/;
-use File::Temp qw/tempfile/;
-use POSIX qw/WIFEXITED WEXITSTATUS WIFSIGNALED WTERMSIG SIGINT SIGQUIT/;
+use Cwd qw/abs_path/;
+use File::Temp qw/tempfile/;
+use File::Spec::Functions qw/curdir catfile/;
+use POSIX qw/WIFEXITED WEXITSTATUS WIFSIGNALED WTERMSIG/;
BEGIN {
no warnings 'redefine';
'version',
);
- my $git = 't/bin/git';
+ my $git = catfile(curdir, qw/t bin git/);
if ($^O eq 'MSWin32') {
unless (-x $git) {
$git .= '.bat';