threads / bug / 22725

[BUG] girocco + git-svn: trunk is not propagated to master

Subject: [BUG] girocco + git-svn: trunk is not propagated to master

## tl;dr

12 messages between Feb 19, 2010 and May 6, 2010.

replies: 11people: 3as markdown or json

Kirill Smelkov· Feb 19, 2010, 13:22 UTC · lore
Hello Petr, Miklos, All,

Recently I've setup an svn mirror on repo.or.cz for docutils projects[1]. Automatic regular updates by `git svn fetch` seem to work, so first thanks for the service.

However master is not updated at all, and also refs/heads/* are not populated from refs/remotes/* it seems.

In Girocco's taskd/clone.sh[2] and jobd/update.sh[3], I see there is a nice setup for master to be bound to trunk and also refs/remotes/heads/* to be propagates to refs/remotes/*:

---- taskd/clone.sh ----
svn://*)
    GIT_DIR=. git svn fetch
    # Neat Trick suggested by Miklos Vajna
    GIT_DIR=. git config remote.origin.url .
    GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
    GIT_DIR=. git config remote.origin.fetch +refs/remotes/trunk:refs/heads/master
    GIT_DIR=. git config remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
    GIT_DIR=. git fetch
---- jobd/update.sh ----
svn://*)
        GIT_DIR=. bang git svn fetch
        GIT_DIR=. bang git fetch

But it seems it does not work. First I see there is a need for quoting, so e.g.

-   GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
+   GIT_DIR=. git config remote.origin.fetch '+refs/remotes/heads/*:refs/heads/*'
but I'm not sure it will fix the problem.
Can we do something about it please?

Thanks beforehand, Kirill

[1] http://repo.or.cz/w/docutils.git [2] http://repo.or.cz/w/girocco.git/blob/HEAD:/taskd/clone.sh#l25 [3] http://repo.or.cz/w/girocco.git/blob/HEAD:/jobd/update.sh#l41

Miklos Vajna· Feb 20, 2010, 23:42 UTC · re: Kirill Smelkov · lore

Re: [BUG] girocco + git-svn: trunk is not propagated to master

On Fri, Feb 19, 2010 at 04:22:07PM +0300, Kirill Smelkov <kirr@mns.spb.ru> wrote:
Show 9 quoted lines
> ---- taskd/clone.sh ----
> svn://*)
>     GIT_DIR=. git svn fetch
>     # Neat Trick suggested by Miklos Vajna
>     GIT_DIR=. git config remote.origin.url .
>     GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
>     GIT_DIR=. git config remote.origin.fetch +refs/remotes/trunk:refs/heads/master
>     GIT_DIR=. git config remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
>     GIT_DIR=. git fetch
Here is the original blog post:
http://vmiklos.hu/blog/svn-ggit-conversion-using-git-svn
Show 13 quoted lines
> ---- jobd/update.sh ----
> svn://*)
>         GIT_DIR=. bang git svn fetch
>         GIT_DIR=. bang git fetch
> 
> 
> But it seems it does not work. First I see there is a need for quoting,
> so e.g. 
> 
> -   GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
> +   GIT_DIR=. git config remote.origin.fetch '+refs/remotes/heads/*:refs/heads/*'
> 
> but I'm not sure it will fix the problem.

When I tried this technique in ooo-build, I did not need quoting. Though it won't hurt, sure.

> Can we do something about it please?
Did you get any error message?
Kirill Smelkov· Feb 21, 2010, 17:19 UTC · re: Miklos Vajna · lore

Re: [BUG] girocco + git-svn: trunk is not propagated to master

On Sun, Feb 21, 2010 at 12:42:00AM +0100, Miklos Vajna wrote:
Show 14 quoted lines
> On Fri, Feb 19, 2010 at 04:22:07PM +0300, Kirill Smelkov <kirr@mns.spb.ru> wrote:
> > ---- taskd/clone.sh ----
> > svn://*)
> >     GIT_DIR=. git svn fetch
> >     # Neat Trick suggested by Miklos Vajna
> >     GIT_DIR=. git config remote.origin.url .
> >     GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
> >     GIT_DIR=. git config remote.origin.fetch +refs/remotes/trunk:refs/heads/master
> >     GIT_DIR=. git config remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
> >     GIT_DIR=. git fetch
> 
> Here is the original blog post:
> 
> http://vmiklos.hu/blog/svn-ggit-conversion-using-git-svn
Thanks
Show 16 quoted lines
> > ---- jobd/update.sh ----
> > svn://*)
> >         GIT_DIR=. bang git svn fetch
> >         GIT_DIR=. bang git fetch
> > 
> > 
> > But it seems it does not work. First I see there is a need for quoting,
> > so e.g. 
> > 
> > -   GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
> > +   GIT_DIR=. git config remote.origin.fetch '+refs/remotes/heads/*:refs/heads/*'
> > 
> > but I'm not sure it will fix the problem.
> 
> When I tried this technique in ooo-build, I did not need quoting. Though
> it won't hurt, sure.

Yes it should work as is, but quoting wildcards is defensive. Just in case.

> > Can we do something about it please?
> 
> Did you get any error message?
No, it sent me an email that cloning was ok and that was it...

... I think I've found the problem -- it's that we need to use `git config --add` in order to setup multivars. Please find patches below. Petr, if everything is ok with them, could you please apply it? Thanks.

From fd625c71d1f6ec88bd58faaca24da29c1fb8b5b3 Mon Sep 17 00:00:00 2001
From: Kirill Smelkov <kirr@mns.spb.ru>
Date: Sun, 21 Feb 2010 20:02:00 +0300
Subject: [PATCH 1/2] taskd/clone: Don't forget to use 'git config --add' for multivars setup

Neat Trick suggested by Miklos Vajna setups origin remote as '.' and also setups 3 refspecs for remotes.origin.fetch.

The trick is nice indeed, but in order to setup config multivar, one have to use explicit --add option for `git config' (*) or else old var value is just replaced.

The problem showed in svn-mirror repositories with stale master (was not updating from trunk) and also as lack of branches -- that's understandable -- we had '+refs/remotes/tags/*:refs/tags/*' config last, and tags were working OK.

Fix it.
(*) explicit --add was needed since 89c4afe0 (Add --add option to
    git-repo-config) in git.git, which dates to git v1.4.4.2-225-g89c4afe
---
 taskd/clone.sh |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/taskd/clone.sh b/taskd/clone.sh
index 962c526..0f5d6fa 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -28,8 +28,8 @@ case "$url" in
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
 		GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/trunk:refs/heads/master
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
+		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/trunk:refs/heads/master
+		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
 		GIT_DIR=. git fetch
 		;;
 	darcs://*)
-- 
1.7.0.50.g50c1



From 79477bd2cdc60574eb4a07d2dc2c97d9fa663e27 Mon Sep 17 00:00:00 2001
From: Kirill Smelkov <kirr@mns.spb.ru>
Date: Sun, 21 Feb 2010 20:11:09 +0300
Subject: [PATCH 2/2] taskd/clone: quote shell metacharacters where appropriate

At present this involves svn mirror setup -- refspec mappings contain
shell wildcards. Quote them just in case.
---
 taskd/clone.sh |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/taskd/clone.sh b/taskd/clone.sh
index 0f5d6fa..cfcb3b1 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -27,9 +27,9 @@ case "$url" in
 		GIT_DIR=. git svn fetch
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
-		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/trunk:refs/heads/master
-		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
+		GIT_DIR=. git config remote.origin.fetch '+refs/remotes/heads/*:refs/heads/*'
+		GIT_DIR=. git config --add remote.origin.fetch '+refs/remotes/trunk:refs/heads/master'
+		GIT_DIR=. git config --add remote.origin.fetch '+refs/remotes/tags/*:refs/tags/*'
 		GIT_DIR=. git fetch
 		;;
 	darcs://*)
-- 
1.7.0.50.g50c1
Kirill Smelkov· Feb 22, 2010, 08:50 UTC · re: Kirill Smelkov · lore

[PATCH] Teach Girocco to mirror http:// style SVN repos

On Sun, Feb 21, 2010 at 08:19:39PM +0300, Kirill Smelkov wrote:
> ... I think I've found the problem -- it's that we need to use
> `git config --add` in order to setup multivars. Please find patches below.
> Petr, if everything is ok with them, could you please apply it? Thanks.

And also, while at it, I was always dreaming about http:// style svn mirroring support at repo.or.cz . Petr, they say dreams always come true. Could you please apply it?

>From 7cb7218b23c7ab89609a812137e1d621603aabc6 Mon Sep 17 00:00:00 2001
From: Kirill Smelkov <kirr@mns.spb.ru>
Date: Mon, 22 Feb 2010 11:37:35 +0300
Subject: [PATCH] Teach Girocco to mirror http:// style SVN repos

Currently we can mirror svn:// repos, but http:// is assumed to be used for Git. Teach the tool to use svn+http:// style urls for http:// svn repositories.

This is very needed, because most SVN hosting services only provide http:// style access to their services. e.g. google code, python.org, etc...

This has not been tested on full Girocco installation - just partly. But
if it works, let's also add svn+https later.
---
 Girocco/Util.pm |    2 +-
 jobd/update.sh  |    2 +-
 taskd/clone.sh  |    6 ++++--
 3 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/Girocco/Util.pm b/Girocco/Util.pm
index e2f7854..969cb3c 100644
--- a/Girocco/Util.pm
+++ b/Girocco/Util.pm
@@ -111,7 +111,7 @@ sub valid_web_url {
 }
 sub valid_repo_url {
 	$_ = $_[0];
-	/^(http|git|svn|darcs|bzr):\/\/[a-zA-Z0-9-.:]+(\/[_\%a-zA-Z0-9.\/~-]*)?$/;
+	/^(http|git|svn(\+http)?|darcs|bzr):\/\/[a-zA-Z0-9-.:]+(\/[_\%a-zA-Z0-9.\/~-]*)?$/;
 }
 
 
diff --git a/jobd/update.sh b/jobd/update.sh
index e09ef95..65e0455 100755
--- a/jobd/update.sh
+++ b/jobd/update.sh
@@ -38,7 +38,7 @@ mail="$(config_get owner)"
 bang git for-each-ref --format '%(refname)	%(objectname)' >.refs-before
 
 case "$url" in
-	svn://*)
+	svn://* | svn+http://*)
 		GIT_DIR=. bang git svn fetch
 		GIT_DIR=. bang git fetch
 		;;
diff --git a/taskd/clone.sh b/taskd/clone.sh
index cfcb3b1..e634388 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -22,8 +22,10 @@ mail="$(config_get owner)"
 # Initial mirror
 echo "Initiating mirroring..."
 case "$url" in
-	svn://*)
-		GIT_DIR=. git svn init -s "$url"
+	svn://* | svn+http://*)
+		# we just remote svn+ here, so svn+http://... becomes http://...
+		svnurl="${url#svn+}"
+		GIT_DIR=. git svn init -s "$svnurl"
 		GIT_DIR=. git svn fetch
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
-- 
1.7.0.50.g50c1
Kirill Smelkov· Mar 22, 2010, 11:07 UTC · re: Kirill Smelkov · lore

[PATCH 0/3] girocco + git-svn: trunk is not propagated to master + more... (resend)

On Mon, Feb 22, 2010 at 11:50:29AM +0300, Kirill Smelkov wrote:
Show 8 quoted lines
> On Sun, Feb 21, 2010 at 08:19:39PM +0300, Kirill Smelkov wrote:
> > ... I think I've found the problem -- it's that we need to use
> > `git config --add` in order to setup multivars. Please find patches below.
> > Petr, if everything is ok with them, could you please apply it? Thanks.
>
> And also, while at it, I was always dreaming about http:// style svn
> mirroring support at repo.or.cz . Petr, they say dreams always come
> true. Could you please apply it?
Petr,

Since I was once recognized as russian spam in Junio's inbox, and it's already one month since I originally posted, I'd like to "resend" this stuff. Could you please ACK/NAK?

Thanks beforehand, Kirill

http://marc.info/?l=git&m=126677421607801&w=2 http://marc.info/?l=git&m=126682864619850&w=2

Kirill Smelkov (3):
  taskd/clone: Don't forget to use 'git config --add' for multivars
    setup
  taskd/clone: quote shell metacharacters where appropriate
  Teach Girocco to mirror http:// style SVN repos
 Girocco/Util.pm |    2 +-
 jobd/update.sh  |    2 +-
 taskd/clone.sh  |   12 +++++++-----
 3 files changed, 9 insertions(+), 7 deletions(-)
Kirill Smelkov· Mar 22, 2010, 11:07 UTC · re: Kirill Smelkov · lore

[PATCH 1/3] taskd/clone: Don't forget to use 'git config --add' for multivars setup

Neat Trick suggested by Miklos Vajna setups origin remote as '.' and also setups 3 refspecs for remotes.origin.fetch.

The trick is nice indeed, but in order to setup config multivar, one have to use explicit --add option for `git config' (*) or else old var value is just replaced.

The problem showed in svn-mirror repositories with stale master (was not updating from trunk) and also as lack of branches -- that's understandable -- we had '+refs/remotes/tags/*:refs/tags/*' config last, and tags were working OK.

Fix it.
(*) explicit --add was needed since 89c4afe0 (Add --add option to
    git-repo-config) in git.git, which dates to git v1.4.4.2-225-g89c4afe
---
 taskd/clone.sh |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/taskd/clone.sh b/taskd/clone.sh
index 962c526..0f5d6fa 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -28,8 +28,8 @@ case "$url" in
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
 		GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/trunk:refs/heads/master
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
+		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/trunk:refs/heads/master
+		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
 		GIT_DIR=. git fetch
 		;;
 	darcs://*)
-- 
1.7.0.2.284.gafe27d
Kirill Smelkov· Mar 22, 2010, 11:08 UTC · re: Kirill Smelkov · lore

[PATCH 2/3] taskd/clone: quote shell metacharacters where appropriate

At present this involves svn mirror setup -- refspec mappings contain
shell wildcards. Quote them just in case.
---
 taskd/clone.sh |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/taskd/clone.sh b/taskd/clone.sh
index 0f5d6fa..cfcb3b1 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -27,9 +27,9 @@ case "$url" in
 		GIT_DIR=. git svn fetch
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
-		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/trunk:refs/heads/master
-		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
+		GIT_DIR=. git config remote.origin.fetch '+refs/remotes/heads/*:refs/heads/*'
+		GIT_DIR=. git config --add remote.origin.fetch '+refs/remotes/trunk:refs/heads/master'
+		GIT_DIR=. git config --add remote.origin.fetch '+refs/remotes/tags/*:refs/tags/*'
 		GIT_DIR=. git fetch
 		;;
 	darcs://*)
-- 
1.7.0.2.284.gafe27d
Kirill Smelkov· Mar 22, 2010, 11:08 UTC · re: Kirill Smelkov · lore

[PATCH 3/3] Teach Girocco to mirror http:// style SVN repos

From: Kirill Smelkov <kirr@landau.phys.spbu.ru>

Currently we can mirror svn:// repos, but http:// is assumed to be used for Git. Teach the tool to use svn+http:// style urls for http:// svn repositories.

This is very needed, because most SVN hosting services only provide http:// style access to their services. e.g. google code, python.org, etc...

This has not been tested on full Girocco installation - just partly. But
if it works, let's also add svn+https later.
---
 Girocco/Util.pm |    2 +-
 jobd/update.sh  |    2 +-
 taskd/clone.sh  |    6 ++++--
 3 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/Girocco/Util.pm b/Girocco/Util.pm
index e2f7854..969cb3c 100644
--- a/Girocco/Util.pm
+++ b/Girocco/Util.pm
@@ -111,7 +111,7 @@ sub valid_web_url {
 }
 sub valid_repo_url {
 	$_ = $_[0];
-	/^(http|git|svn|darcs|bzr):\/\/[a-zA-Z0-9-.:]+(\/[_\%a-zA-Z0-9.\/~-]*)?$/;
+	/^(http|git|svn(\+http)?|darcs|bzr):\/\/[a-zA-Z0-9-.:]+(\/[_\%a-zA-Z0-9.\/~-]*)?$/;
 }
 
 
diff --git a/jobd/update.sh b/jobd/update.sh
index e09ef95..65e0455 100755
--- a/jobd/update.sh
+++ b/jobd/update.sh
@@ -38,7 +38,7 @@ mail="$(config_get owner)"
 bang git for-each-ref --format '%(refname)	%(objectname)' >.refs-before
 
 case "$url" in
-	svn://*)
+	svn://* | svn+http://*)
 		GIT_DIR=. bang git svn fetch
 		GIT_DIR=. bang git fetch
 		;;
diff --git a/taskd/clone.sh b/taskd/clone.sh
index cfcb3b1..e634388 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -22,8 +22,10 @@ mail="$(config_get owner)"
 # Initial mirror
 echo "Initiating mirroring..."
 case "$url" in
-	svn://*)
-		GIT_DIR=. git svn init -s "$url"
+	svn://* | svn+http://*)
+		# we just remote svn+ here, so svn+http://... becomes http://...
+		svnurl="${url#svn+}"
+		GIT_DIR=. git svn init -s "$svnurl"
 		GIT_DIR=. git svn fetch
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
-- 
1.7.0.2.284.gafe27d
Petr Baudis· May 5, 2010, 18:54 UTC · re: Kirill Smelkov · lore

Re: [PATCH 3/3] Teach Girocco to mirror http:// style SVN repos

On Mon, Mar 22, 2010 at 02:08:01PM +0300, Kirill Smelkov wrote:
Show 12 quoted lines
> From: Kirill Smelkov <kirr@landau.phys.spbu.ru>
> 
> Currently we can mirror svn:// repos, but http:// is assumed to be used
> for Git. Teach the tool to use svn+http:// style urls for http:// svn
> repositories.
> 
> This is very needed, because most SVN hosting services only provide
> http:// style access to their services. e.g. google code, python.org,
> etc...
> 
> This has not been tested on full Girocco installation - just partly. But
> if it works, let's also add svn+https later.
Thanks, applied.

(BTW, it would be much better if you sent patches to admin@repo.or.cz instead. At least in theory - if anyone is interested helping out with various rather badly needed repo.or.cz tasks [http://repo.or.cz/w/girocco.git/blob/rorcz:/TODO], please let me know and I will give you some admin permissions.)

-- 
				Petr "Pasky" Baudis
When I feel like exercising, I just lie down until the feeling
goes away.  -- xed_over
Kirill Smelkov· May 6, 2010, 07:18 UTC · re: Petr Baudis · lore

Re: [PATCH 3/3] Teach Girocco to mirror http:// style SVN repos

On Wed, May 05, 2010 at 08:54:09PM +0200, Petr Baudis wrote:
Show 18 quoted lines
> On Mon, Mar 22, 2010 at 02:08:01PM +0300, Kirill Smelkov wrote:
> > From: Kirill Smelkov <kirr@landau.phys.spbu.ru>
> > 
> > Currently we can mirror svn:// repos, but http:// is assumed to be used
> > for Git. Teach the tool to use svn+http:// style urls for http:// svn
> > repositories.
> > 
> > This is very needed, because most SVN hosting services only provide
> > http:// style access to their services. e.g. google code, python.org,
> > etc...
> > 
> > This has not been tested on full Girocco installation - just partly. But
> > if it works, let's also add svn+https later.
> 
> Thanks, applied.
> 
> (BTW, it would be much better if you sent patches to admin@repo.or.cz
> instead.
I see, and thanks for applying this one finally.

Btw, would you please also apply those two important (one of them) fixes to svn mirroring setup?

*Please*
>From bdb55d014374c0f594ab70d7b22617fc61201d81 Mon Sep 17 00:00:00 2001
From: Kirill Smelkov <kirr@mns.spb.ru>
Date: Sun, 21 Feb 2010 20:02:00 +0300
Subject: [PATCH 1/2] taskd/clone: Don't forget to use 'git config --add' for multivars setup

Neat Trick suggested by Miklos Vajna setups origin remote as '.' and also setups 3 refspecs for remotes.origin.fetch.

The trick is nice indeed, but in order to setup config multivar, one have to use explicit --add option for `git config' (*) or else old var value is just replaced.

The problem showed in svn-mirror repositories with stale master (was not updating from trunk) and also as lack of branches -- that's understandable -- we had '+refs/remotes/tags/*:refs/tags/*' config last, and tags were working OK.

Fix it.
(*) explicit --add was needed since 89c4afe0 (Add --add option to
    git-repo-config) in git.git, which dates to git v1.4.4.2-225-g89c4afe
---
 taskd/clone.sh |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/taskd/clone.sh b/taskd/clone.sh
index f99d046..270626c 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -30,8 +30,8 @@ case "$url" in
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
 		GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/trunk:refs/heads/master
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
+		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/trunk:refs/heads/master
+		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
 		GIT_DIR=. git fetch
 		;;
 	darcs://*)
-- 
1.7.1.16.g5dc5



>From 0db9ccc033ac6b82ff3026fa89846616a9b74f9e Mon Sep 17 00:00:00 2001
From: Kirill Smelkov <kirr@mns.spb.ru>
Date: Sun, 21 Feb 2010 20:11:09 +0300
Subject: [PATCH 2/2] taskd/clone: quote shell metacharacters where appropriate

At present this involves svn mirror setup -- refspec mappings contain
shell wildcards. Quote them just in case.
---
 taskd/clone.sh |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/taskd/clone.sh b/taskd/clone.sh
index 270626c..e634388 100755
--- a/taskd/clone.sh
+++ b/taskd/clone.sh
@@ -29,9 +29,9 @@ case "$url" in
 		GIT_DIR=. git svn fetch
 		# Neat Trick suggested by Miklos Vajna
 		GIT_DIR=. git config remote.origin.url .
-		GIT_DIR=. git config remote.origin.fetch +refs/remotes/heads/*:refs/heads/*
-		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/trunk:refs/heads/master
-		GIT_DIR=. git config --add remote.origin.fetch +refs/remotes/tags/*:refs/tags/*
+		GIT_DIR=. git config remote.origin.fetch '+refs/remotes/heads/*:refs/heads/*'
+		GIT_DIR=. git config --add remote.origin.fetch '+refs/remotes/trunk:refs/heads/master'
+		GIT_DIR=. git config --add remote.origin.fetch '+refs/remotes/tags/*:refs/tags/*'
 		GIT_DIR=. git fetch
 		;;
 	darcs://*)
-- 
1.7.1.16.g5dc5




> At least in theory - if anyone is interested helping out with
> various rather badly needed repo.or.cz tasks
> [http://repo.or.cz/w/girocco.git/blob/rorcz:/TODO], please let me know
> and I will give you some admin permissions.)

Thanks for the offer. Unfortunately I can't commit to this task :(


Thanks,
Kirill
Petr Baudis· May 6, 2010, 07:36 UTC · re: Kirill Smelkov · lore

Re: [PATCH 3/3] Teach Girocco to mirror http:// style SVN repos

On Thu, May 06, 2010 at 11:18:42AM +0400, Kirill Smelkov wrote:
> Btw, would you please also apply those two important (one of them) fixes
> to svn mirroring setup?
> 
> *Please*
Applied, thanks.
-- 
				Petr "Pasky" Baudis
When I feel like exercising, I just lie down until the feeling
goes away.  -- xed_over
Kirill Smelkov· May 6, 2010, 08:32 UTC · re: Petr Baudis · lore

Re: [PATCH 3/3] Teach Girocco to mirror http:// style SVN repos

On Thu, May 06, 2010 at 09:36:47AM +0200, Petr Baudis wrote:
Show 7 quoted lines
> On Thu, May 06, 2010 at 11:18:42AM +0400, Kirill Smelkov wrote:
> > Btw, would you please also apply those two important (one of them) fixes
> > to svn mirroring setup?
> > 
> > *Please*
> 
> Applied, thanks.
Thanks!

← back to recent threads