From: Luca Barbato <lu_zero@gentoo.org>
To: Eric Wong <normalperson@yhbt.net>
Cc: git@vger.kernel.org
Subject: Re: [patch] Make git-svn init accept a target dir
Date: Thu, 29 Jun 2006 02:41:14 +0200 [thread overview]
Message-ID: <44A321AA.6080703@gentoo.org> (raw)
In-Reply-To: <20060629002852.GA29147@hand.yhbt.net>
[-- Attachment #1: Type: text/plain, Size: 199 bytes --]
Eric Wong wrote:
>
> Sounds useful and I'll probably accept it, but I don't see the actual
> patch, though...
>
ops...
--
Luca Barbato
Gentoo/linux Gentoo/PPC
http://dev.gentoo.org/~lu_zero
[-- Attachment #2: git-svn-init.patch --]
[-- Type: text/plain, Size: 1042 bytes --]
--- /usr/bin/git-svn 2006-06-29 00:57:26.000000000 +0200
+++ /usr/bin/git-svn.new 2006-06-28 03:40:11.000000000 +0200
@@ -5,7 +5,7 @@
use strict;
use vars qw/ $AUTHOR $VERSION
$SVN_URL $SVN_INFO $SVN_WC $SVN_UUID
- $GIT_SVN_INDEX $GIT_SVN
+ $GIT_SVN_INDEX $GIT_SVN $REPO_PATH
$GIT_DIR $REV_DIR/;
$AUTHOR = 'Eric Wong <normalperson@yhbt.net>';
$VERSION = '1.1.0-pre';
@@ -98,6 +98,7 @@
$GIT_SVN ||= $ENV{GIT_SVN_ID} || 'git-svn';
$GIT_SVN_INDEX = "$GIT_DIR/$GIT_SVN/index";
$SVN_URL = undef;
+$REPO_PATH = undef;
$REV_DIR = "$GIT_DIR/$GIT_SVN/revs";
$SVN_WC = "$GIT_DIR/$GIT_SVN/tree";
@@ -227,6 +228,16 @@
sub init {
$SVN_URL = shift or die "SVN repository location required " .
"as a command-line argument\n";
+ $REPO_PATH = shift;
+
+ if ($REPO_PATH) {
+ unless (-d $REPO_PATH) {
+ mkpath([$REPO_PATH]);
+ }
+ $GIT_DIR=$REPO_PATH . "/.git";
+ $ENV{GIT_DIR}=$GIT_DIR;
+ }
+
unless (-d $GIT_DIR) {
sys('git-init-db');
}
prev parent reply other threads:[~2006-06-29 0:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-28 23:07 [patch] Make git-svn init accept a target dir Luca Barbato
2006-06-29 0:28 ` Eric Wong
2006-06-29 0:41 ` Luca Barbato [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=44A321AA.6080703@gentoo.org \
--to=lu_zero@gentoo.org \
--cc=git@vger.kernel.org \
--cc=normalperson@yhbt.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.