diff options
author | Petr Baudis <pasky@suse.cz> | 2006-06-25 05:54:28 +0400 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-07-03 04:14:42 +0400 |
commit | 71efe0ca3c9c8bc8e7863e583cd2a808769c3bab (patch) | |
tree | c2d7ba2f72200a537e458de89621a81170f83c56 /perl/Git.pm | |
parent | 24c4b7143639cc821b6d06f9e125429e65dad8cd (diff) |
Git.pm: Fix Git->repository("/somewhere/totally/elsewhere")
Signed-off-by: Petr Baudis <pasky@suse.cz>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'perl/Git.pm')
-rw-r--r-- | perl/Git.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/perl/Git.pm b/perl/Git.pm index 5ec7ef8c24..0581447757 100644 --- a/perl/Git.pm +++ b/perl/Git.pm @@ -178,7 +178,8 @@ sub repository { }; if ($dir) { - $opts{Repository} = abs_path($dir); + $dir =~ m#^/# or $dir = $opts{Directory} . '/' . $dir; + $opts{Repository} = $dir; # If --git-dir went ok, this shouldn't die either. my $prefix = $search->command_oneline('rev-parse', '--show-prefix'); |