Experimental Git repository available

2 views
Skip to first unread message

Jacob Kaplan-Moss

unread,
Jun 19, 2008, 12:39:22 PM6/19/08
to django-d...@googlegroups.com
Hi folks --

I've published an experimental Git clone of Django's SVN repository
(created with git-svn). If you're a Git user and want to use this
repository, be my guest. Please still upload patches to Trac for
review, but mention you're using my clone so I can more easily apply
patches from you. Also let me know if you publish your clones
anywhere; I'll add 'em as remotes.

Note that this is in no way official, this is just me fooling around
with new tech. It's entirely possible that this won't actually save
anyone any time, but since I'm fooling with Git I thought I'd give
this a shot. Please don't try to turn this into a "Django should use
Git!" thread; if you do I'll just ignore you. We're not switching from
SVN any time in the foreseeable future.

OK, so the details:

Repository: git://djangoproject.com/django
Gitweb: http://code.djangoproject.com/git/?p=django

Jacob

alex....@gmail.com

unread,
Jun 19, 2008, 12:55:12 PM6/19/08
to Django developers
Is this only going to offer the trunk branch?

On Jun 19, 11:39 am, "Jacob Kaplan-Moss" <jacob.kaplanm...@gmail.com>
wrote:

Ben Ford

unread,
Jun 19, 2008, 12:59:26 PM6/19/08
to django-d...@googlegroups.com
Hi Jacob,

This sounds like a nice idea... Any plans to do a mercurial repo (a-la the documentation refactor)? Am I right in thinking that support of SVN <=> HG is less complete than GIT <=> SVN?

Cheers,
Ben




--
Regards,
Ben Ford
ben.f...@gmail.com
+447792598685

Ariel Mauricio Nunez Gomez

unread,
Jun 19, 2008, 1:02:13 PM6/19/08
to django-d...@googlegroups.com
Something like this?
http://hg.dpaste.com/django/

Jacob Kaplan-Moss

unread,
Jun 19, 2008, 1:07:25 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 11:55 AM, alex....@gmail.com
<alex....@gmail.com> wrote:
> Is this only going to offer the trunk branch?

Until I learn more about Git, yes :)

If you know the correct incantation to add other git-svn-created
branches, feel free to school me :)

Jacob

Jacob Kaplan-Moss

unread,
Jun 19, 2008, 1:09:07 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 11:59 AM, Ben Ford <ben.f...@gmail.com> wrote:
> This sounds like a nice idea... Any plans to do a mercurial repo (a-la the
> documentation refactor)? Am I right in thinking that support of SVN <=> HG
> is less complete than GIT <=> SVN?

Yeah, hgsvn is one-way, which git-svn has the "dcommit" command
which'll commit back to SVN. I'm really not much of a git fan, but
git-svn makes a better svn than svn does, if you know what I mean.

Jacob

Tom Tobin

unread,
Jun 19, 2008, 1:09:37 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 11:39 AM, Jacob Kaplan-Moss
<jacob.ka...@gmail.com> wrote:
> I've published an experimental Git clone of Django's SVN repository
> (created with git-svn). If you're a Git user and want to use this
> repository, be my guest. Please still upload patches to Trac for
> review, but mention you're using my clone so I can more easily apply
> patches from you. Also let me know if you publish your clones
> anywhere; I'll add 'em as remotes.

Noted this on the appropriate wiki page (and cleaned up the section on
DVCS mirrors):

http://code.djangoproject.com/wiki/DjangoBranches

Alexander Solovyov

unread,
Jun 19, 2008, 1:52:15 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 8:09 PM, Jacob Kaplan-Moss
<jacob.ka...@gmail.com> wrote:
>
> On Thu, Jun 19, 2008 at 11:59 AM, Ben Ford <ben.f...@gmail.com> wrote:
>> This sounds like a nice idea... Any plans to do a mercurial repo (a-la the
>> documentation refactor)? Am I right in thinking that support of SVN <=> HG
>> is less complete than GIT <=> SVN?
>
> Yeah, hgsvn is one-way,

Hmmmm....

>hg help convert
hg convert [OPTION]... SOURCE [DEST [REVMAP]]

Convert a foreign SCM repository to a Mercurial one.
...
Accepted destination formats:
- Mercurial
- Subversion (history on branches is not preserved)

That's hg 1.0.1

--
Alexander

dankelley

unread,
Jun 19, 2008, 2:10:27 PM6/19/08
to Django developers
You're a gentleman and a scholar, Jacob.

I think you'll find that git is a tool that feels good in the hand.

Waylan Limberg

unread,
Jun 19, 2008, 2:21:49 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 1:52 PM, Alexander Solovyov
<pir...@piranha.org.ua> wrote:
>
> On Thu, Jun 19, 2008 at 8:09 PM, Jacob Kaplan-Moss
> <jacob.ka...@gmail.com> wrote:
>> Yeah, hgsvn is one-way,
>
> Hmmmm....
>
>>hg help convert
> hg convert [OPTION]... SOURCE [DEST [REVMAP]]
>
> Convert a foreign SCM repository to a Mercurial one.

True, but that doesn't address pushing changes back to SVN, at least
not practically. Mercurial's own docs [1] admit this is a problem
needing improvement. Compare that with git-svn's dcommit command [2].

[1]: http://www.selenic.com/mercurial/wiki/index.cgi/WorkingWithSubversion#head-15564b76f3172721218d34c912aa0c31e156a94b
[2]: http://www.kernel.org/pub/software/scm/git/docs/git-svn.html


--
----
Waylan Limberg
way...@gmail.com

Jeremy Dunck

unread,
Jun 19, 2008, 2:40:07 PM6/19/08
to django-d...@googlegroups.com
I'm just guessing, but I think git-clone doesn't pull in remotes, so
that our clones are getting whatever's your master, hence trunk.
You can make a local copy of a remote branch like so:

git-checkout -b local/branchname branchname

There's no magic in the "local" prefix, it's just to distinguish the
remote branch of the same name.

Plus
git-update-server-info
may be needed...

Ben Ford

unread,
Jun 19, 2008, 3:25:25 PM6/19/08
to django-d...@googlegroups.com
> Something like this?
> http://hg.dpaste.com/django/

Yeah I use that one at the moment, I was getting at a more thing. I'm sure that's more difficult to do with HG then GIT and like Jacob said, it's a moot point anyway :-)

Ben

2008/6/19 Ariel Mauricio Nunez Gomez <ingenie...@gmail.com>:




Michael Elsdörfer

unread,
Jun 19, 2008, 5:03:28 PM6/19/08
to Django developers
> Yeah, hgsvn is one-way, which git-svn has the "dcommit" command
> which'll commit back to SVN. I'm really not much of a git fan, but
> git-svn makes a better svn than svn does, if you know what I mean.

FWIW (I'm currently playing around with all three of them), bazaar
appears to support pushing into svn as well.

Michael

Marc Fargas

unread,
Jun 19, 2008, 5:27:08 PM6/19/08
to django-d...@googlegroups.com
El jue, 19-06-2008 a las 14:03 -0700, Michael Elsdörfer escribió:
> FWIW (I'm currently playing around with all three of them), bazaar
> appears to support pushing into svn as well.

Yes, with bzr-svn. Didn't play too much with that one. But Bazaar is
slow, *really* slow.

--
http://www.marcfargas.com -- will be finished some day.

signature.asc

Tom Tobin

unread,
Jun 19, 2008, 5:42:58 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 4:27 PM, Marc Fargas <tele...@telenieko.com> wrote:
> El jue, 19-06-2008 a las 14:03 -0700, Michael Elsdörfer escribió:
>> FWIW (I'm currently playing around with all three of them), bazaar
>> appears to support pushing into svn as well.
>
> Yes, with bzr-svn. Didn't play too much with that one. But Bazaar is
> slow, *really* slow.

I settled on Bazaar after extensively using both Git and Mercurial;
it's *not* that slow, and it keeps getting faster with aggressive
monthly releases. (But alas, this isn't the right place for DVCS
advocacy.) ^_^

Rob Hudson

unread,
Jun 19, 2008, 6:01:40 PM6/19/08
to django-d...@googlegroups.com

Use the `-T`, `-t`, `-b` flags, or `-s` if the project has a "standard
layout". This should bring over branches and tags as well.

-Rob
--
"ROCK OUT!" \m/. .\m/

Rob Hudson

unread,
Jun 19, 2008, 6:02:24 PM6/19/08
to django-d...@googlegroups.com
On 6/19/08, Rob Hudson <trebor...@gmail.com> wrote:
> Use the `-T`, `-t`, `-b` flags, or `-s` if the project has a "standard
> layout". This should bring over branches and tags as well.

I forgot to reference the man page (which was in my clipboard):
http://www.kernel.org/pub/software/scm/git/docs/git-svn.html

-Rob

Jeremy Dunck

unread,
Jun 19, 2008, 6:14:59 PM6/19/08
to django-d...@googlegroups.com
On Thu, Jun 19, 2008 at 5:02 PM, Rob Hudson <trebor...@gmail.com> wrote:
>
> On 6/19/08, Rob Hudson <trebor...@gmail.com> wrote:
>> Use the `-T`, `-t`, `-b` flags, or `-s` if the project has a "standard
>> layout". This should bring over branches and tags as well.

Oh, er, uh, I didn't notice only trunk was in the published repo-- I
assumed it was a clone problem.

Yeah, what Rob said, except that for sure, django is in the standard
format, so this should work:
git-svn init -s http://code.djangoproject.com/svn/

But I think that just editing .git/config to add this should work:

[svn-remote "svn"]
url = http://code.djangoproject.com/svn
fetch = trunk:refs/remotes/trunk
branches = branches/*:refs/remotes/*
tags = tags/*:refs/remotes/tags/*

Rob Hudson

unread,
Jun 19, 2008, 6:29:25 PM6/19/08
to django-d...@googlegroups.com
On 6/19/08, Jacob Kaplan-Moss <jacob.ka...@gmail.com> wrote:
> Please don't try to turn this into a "Django should use
> Git!" thread; if you do I'll just ignore you. We're not switching from
> SVN any time in the foreseeable future.

I hope you are nearsighted and the foreseeable future isn't too distant. :)

<!-- Ignore, nothing to see here. Really... don't even waste your time...

I just can't help but think that the "network of trust" that Linus
refers to in his Git talk can only help any open source project. For
example, let's say you trust person X to be the source of your
language updates and pull from his Git tree whenever he has a set of
language updates for you. You just have to trust this one person that
they'll do the right thing for that component or area of Django. That
person may have others he trusts to pull merges from, and everything
bubbles up to the top.

This also removes any sort of special status of committers and
authorizing someone as a committer. Everyone can commit to their own
trees/branches, or experiment with features/fixes/updates all they
want, and if it's good, someone can pull from it.

You already know all the benefits of distributed SCM I'm sure. Plus,
there are obviously some key infrastructure changes that would have to
take place *if* Django were to switch to Git -- like Trac, for
example. So even if Git is an obvious choice over SVN, the
neighboring tools play a big factor as well.

But I'm excited to see the "fooling around with new tech" and hope for
of a Git move one day. :)

-->

-Rob

Marc Fargas

unread,
Jun 19, 2008, 6:31:24 PM6/19/08
to django-d...@googlegroups.com
El jue, 19-06-2008 a las 17:14 -0500, Jeremy Dunck escribió:
> git-svn init -s http://code.djangoproject.com/svn/

git-svn init -s http://code.djangoproject.com/svn/django

Unless you want djangoproject.com also ;)

signature.asc

Gary Wilson Jr.

unread,
Jun 20, 2008, 1:49:53 AM6/20/08
to django-d...@googlegroups.com
Marc Fargas wrote:
> El jue, 19-06-2008 a las 14:03 -0700, Michael Elsdörfer escribió:
>> FWIW (I'm currently playing around with all three of them), bazaar
>> appears to support pushing into svn as well.
>
> Yes, with bzr-svn.

Be advised, though, that currently bzr-svn will dump out a ton of svn
properties into your repo [1]. Then, if you say to yourself "what the
heck just happened!?" and go revert that revision (removing the
properties), you will not be able to ever branch the repo again using
bzr-svn until this bug [2] is fixed. Wish I would have known that
before I did it :)

Gary

[1]
http://samba.org/~jelmer/bzr-svn/FAQ.html#bzr-svn-sets-all-kinds-of-file-properties-when-pushing-revisions-into-subversion-is-this-really-necessary
[2] https://bugs.launchpad.net/bzr-svn/+bug/174690

Jeffrey Gelens

unread,
Jun 20, 2008, 4:05:26 AM6/20/08
to Django developers
On Jun 20, 3:21 am, "Waylan Limberg" <way...@gmail.com> wrote:
> On Thu, Jun 19, 2008 at 1:52 PM, Alexander Solovyov
>
> <pira...@piranha.org.ua> wrote:
>
> > On Thu, Jun 19, 2008 at 8:09 PM, Jacob Kaplan-Moss
> > <jacob.kaplanm...@gmail.com> wrote:
> >> Yeah, hgsvn is one-way,
>
> > Hmmmm....
>
> >>hg help convert
> > hg convert [OPTION]... SOURCE [DEST [REVMAP]]
>
> > Convert a foreign SCM repository to a Mercurial one.
>
> True, but that doesn't address pushing changes back to SVN, at least
> not practically. Mercurial's own docs [1] admit this is a problem
> needing improvement. Compare that with git-svn's dcommit command [2].


Actually there is an hgpushsvn included with the hgsvn package. As far
as I tested it is working. I'm not sure why it isn't in the hgsvn
docs, but I guess it is not tested well enough yet.

--
Jeffrey Gelens

David Reynolds

unread,
Jun 20, 2008, 4:35:40 AM6/20/08
to django-d...@googlegroups.com

On 19 Jun 2008, at 6:07 pm, Jacob Kaplan-Moss wrote:

> If you know the correct incantation to add other git-svn-created
> branches, feel free to school me :)

I think Brian Rosner covered pulling in all branches from svn on his
screencast about django and git [0] but I can't off the top of my
head remember how he did it.

http://oebfare.com/blog/2008/jan/23/using-git-django-screencast/

--
David Reynolds
da...@reynoldsfamily.org.uk

Michael Radziej

unread,
Jun 20, 2008, 5:30:13 AM6/20/08
to django-d...@googlegroups.com

I use git-svnimport, which provides only one-way conversion from svn to git.
It converts all branches. But it's going to be deprecated ...

Anyway, I use it, and I sync hourly from svn. It's available at

git://git.spieleck.de/django

Please send me an email if you plan to use it regularly.


Michael

Reply all
Reply to author
Forward
0 new messages