[SciPy-dev] Scipy workflow (and not tools).

Pauli Virtanen pav@iki...
Thu Feb 26 18:08:01 CST 2009


Fri, 27 Feb 2009 00:48:00 +0200, Stéfan van der Walt wrote:

> 2009/2/27 Pauli Virtanen <pav@iki.fi>:
>> If you want to discuss Git, you can probably steal from here:
>>
>>        http://scipy.org/scipy/numpy/wiki/GitMirror
> 
> Ah, yes, good reminder!
> 
> Could you give me a quick rundown of why you used --mirror earlier on
> when adding the remote?

The --mirror option adds

	fetch = +refs/*:refs/*
	mirror = yes

to [remote "origin"]. So one wouldn't need to edit .git/config manually.

However, the --mirror has another effect which I missed earlier: it makes 
the remote consider all heads its own, so that "git remote prune origin" 
would drop all branches, including local ones. Similar issue with
"git fetch". So I think it's not the correct solution.

    ***

But all of that is moot now. I finally figured out that I must push to 
the mirror with

	git push git@github.com:pv/numpy-svn.git \
		+refs/remotes/*:refs/heads/* +master

Then it can be cloned simply with

	git clone --origin svn git://github.com/pv/scipy-svn.git

And "--origin svn" only because we want svn/trunk instead of origin/trunk.
Also git-svn can be activated:

	git svn init -s --prefix=svn/ http://svn.scipy.org/svn/scipy
	git svn rebase -l

And as a bonus, the SVN branches are visible on Github!

I'll update the GitMirror page.

-- 
Pauli Virtanen



More information about the Scipy-dev mailing list