From: Adam Brewster Date: Tue, 4 Aug 2009 01:40:38 +0000 (-0400) Subject: svn: Honor --prefix option in init without --stdlayout X-Git-Tag: v1.6.5-rc0~90^2~1 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=63de84ad60984105b1cd60fb888968b352539313;p=git.git svn: Honor --prefix option in init without --stdlayout Most users who type git svn init file:///tmp/repo --prefix=my-svn/ would expect the root of the svn repository to be tracked by refs/remotes/my-svn/git-svn. Acked-by: Eric Wong --- diff --git a/git-svn.perl b/git-svn.perl index d07581072..fa8583963 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -3317,7 +3317,8 @@ sub _new { $repo_id = $Git::SVN::default_repo_id; } unless (defined $ref_id && length $ref_id) { - $_[2] = $ref_id = $Git::SVN::default_ref_id; + $_prefix = '' unless defined($_prefix); + $_[2] = $ref_id = $_prefix . $Git::SVN::default_ref_id; } $_[1] = $repo_id; my $dir = "$ENV{GIT_DIR}/svn/$ref_id";