git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: RFD: git-bzr: anyone interested?

From
ILIlari Liusvaara <ilari.liusvaara@elisanet.fi>
Date
Feb 19, 2010, 13:55 UTC
Message-ID
<20100219135549.GA31796@Knoppix>
In-Reply-To
<4B7E3856.3080609@gmail.com>
On Fri, Feb 19, 2010 at 02:05:58AM -0500, Gabriel Filion wrote:
Show 8 quoted lines
> 
> The Documentation/git-remote-helpers.txt file wasn't really of much help
> .. It really only barely scratches the subject, but it does not mention
> how remote-helpers really work internally (e.g. how do they get called:
> based on protocol used in URLs?)
> 
> I'm still trying to dig up information about how to actually build, test
> and use a remote helper. I'll probably be reading code for examples.
The remote helper is invoked with one or two parameters. 

There are five cases to consider (as rule, first argument is name of remote [pseudo-remote in case URL was used] and the second argument is URL to use, if any):

1) Remote <remote> without URL line but with VCS line value <helper> was used.

The called program: git-remote-<helper> [search $PATH for it]. Number of arguements: 1 1st argument: <remote>

2) Remote <remote> with URL using <helper>::<string> syntax was used.

The called program: git-remote-<helper> [search $PATH for it]. Number of arguments: 2 1st argument: <remote> 2st argument: <string>

3) Remote <remote> with URL using <helper>://<rest-of-URL> syntax was used.

The called program: git-remote-<helper> [serch $PATH for it]. Number of arguments: 2 1st argument: <remote> 2st argument: <helper>://<rest-of-URL>

4) URL using <helper>::<string> syntax was used directly on command line.

The called program: git-remote-<helper> [serch $PATH for it]. Number of arguments: 2 1st argument: <helper>::<string> 2st argument: <string>

5) URL using <helper>://<rest-of-URL> syntax was used directly on command
line.

The called program: git-remote-<helper> [serch $PATH for it]. Number of arguments: 2 1st argument: <helper>://<rest-of-URL> 2st argument: <helper>://<rest-of-URL>

Notes:
- For 2) and 4), the helper name can only contain alphanumeric characters
  0-9, A-Z and a-z.
- For 3) and 5), the helper name can't be any of builtin protocols:
  'rsync', 'file', 'git', 'ssh', 'git+ssh' nor 'ssh+git'.
- <helper>::<string> is the strongest, followed by VCS line,
  <helper>:://<rest-of-URL> is weakest.
-Ilari
Previous: Gabriel FilionNext: Gabriel Filion
Message 9 of 30 in “RFD: git-bzr: anyone interested?”
  1. Gabriel FilionFeb 18, 2010
  2. Sverre RabbelierFeb 18, 2010
  3. Gabriel FilionFeb 19, 2010
  4. Sverre RabbelierFeb 19, 2010
  5. GabrielFeb 19, 2010
  6. Sverre RabbelierFeb 19, 2010
  7. Writing git remote helpersGabriel, Feb 19, 2010
  8. Gabriel FilionFeb 22, 2010
  9. Ilari LiusvaaraFeb 19, 2010
  10. Gabriel FilionFeb 22, 2010
  11. Ilari LiusvaaraFeb 22, 2010
  12. Gabriel FilionFeb 23, 2010
  13. Ilari LiusvaaraFeb 23, 2010
  14. Chris PackhamApr 26, 2010
  15. Dmitrijs LedkovsApr 26, 2010
  16. Chris PackhamApr 27, 2010
  17. Miles BaderApr 27, 2010
  18. Gabriel FilionApr 27, 2010
  19. Dmitrijs LedkovsApr 27, 2010
  20. Chris PackhamApr 27, 2010
  21. Chris PackhamApr 27, 2010
  22. Dmitrijs LedkovsApr 27, 2010
  23. Conrad ParkerAug 6, 2010
  24. Miles BaderAug 7, 2010
  25. Gabriel FilionAug 7, 2010
  26. Miles BaderAug 7, 2010
  27. git-archimport (was: Re: RFD: git-bzr: anyone interested?)Jakub Narebski, Aug 7, 2010
  28. Matthieu MoyAug 7, 2010
  29. Felipe ContrerasFeb 20, 2010
  30. Gabriel FilionFeb 22, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.