On Wed, Jan 06, 2021 at 11:52:35AM +0800, Hongyi Zhao via curl-users wrote:
> On Wed, Jan 6, 2021 at 8:57 AM Dan Fandrich via curl-library
> <curl-library@cool.haxx.se> wrote:
> >
> > On Wed, Jan 06, 2021 at 08:29:21AM +0800, Hongyi Zhao via curl-library 
> > wrote:
> > > $ curl git://git.sv.gnu.org/emacs.git
> > > curl: (1) Protocol "git" not supported or disabled in libcurl
> > >
> > > So, any hints for the git protocol support of (lib)curl?
> >
> > I'm not sure the git: protocol is very useful without the git tool as well.
> > And, the since the git tool already implements the git protocol using 
> > libcurl,
> > I personally don't see much gain, except perhaps for the (very few) 
> > alternative
> > git implementations that might use a built-in git protocol. But, there 
> > would be
> > far too few of those to make this worthwhile.  What is your use case?
> 
> $ git clone git://...

This use case is already developed. All you need to do is run "git clone
git://..." to get libcurl to download the necessary files and use git logic to
unpack them. Since git can use http: under the hood to download files in many
cases, curl *already* has support to do this without adding anything more. What
is missing is support for unpacking files from a git repository after cloning.
That requires a lot more intelligence than a pure file transfer client should
have (e.g., pack files parsing, knowledge of tree objects, etc.) and IMHO
doesn't belong in curl. curl is about getting data onto your machine, not about
doing anything with it afterward.

Dan
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette:   https://curl.se/mail/etiquette.html

Reply via email to