← Back to team overview

dulwich-users team mailing list archive

Re: Push example and client http support

 

On Fri, Apr 22, 2011 at 11:50, Julien Danjou <julien@xxxxxxxxxxx> wrote:

> Hi there,
>
> I've started using Dulwich for a little project, and I like it. Thanks
> for the good job guys. :)
>
> I'm looking for a quick example on how to push objects into a repository
> using dulwich.client. I understood how to fetch, but the
> GitClient.send_pack function and its determine_wants,
> generate_pack_contents arguments is a little too much to handle for me
> right now.
> I think the class may miss a method like the "fetch" one, that wraps
> "fetch_pack".
>

hg-git has examples of actually using the client module, and perhaps Augie
can chime in with some of his experience.


> Still in client.py, it seems there's no support for http(s) client. I
> doubt it's the hardest client to support, so am I missing something, or
> is it really missing for any good reason?
>

It is the hardest to support :)

The stateless HTTP protocol is different from but related to the stateful
TCP wire protocol, so it's not just a matter of making an HTTP connection
instead of TCP/SSH.


> If you have any hint on what should be done to implement, I can't
> promise anything but there's a chance I look into it somedays. :)
>

I would poke around in the Documentation/technical directory of git.git
until you understand the wire protocol; that's basically what I did to
implement HTTP server support. If you have questions, I can help clarify, or
you can ask the git mailing list about things where the documentation is
unclear.


> Thanks,
> --
> Julien Danjou
> ❱ http://julien.danjou.info
>
> _______________________________________________
> Mailing list: https://launchpad.net/~dulwich-users
> Post to     : dulwich-users@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~dulwich-users
> More help   : https://help.launchpad.net/ListHelp
>
>

Follow ups

References