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

Re: [PATCH] Add support for host aliases in config files

From
Jakub Narebski <jnareb@gmail.com>
Date
Jan 25, 2008, 21:48 UTC
Message-ID
<200801252248.12682.jnareb@gmail.com>
In-Reply-To
<alpine.LNX.1.00.0801251535380.13593@iabervon.org>
Daniel Barkalow wrote:
Show 33 quoted lines
> So, something like:
> 
> diff --git a/Documentation/urls.txt b/Documentation/urls.txt
> index 81ac17f..f47b9e0 100644
> --- a/Documentation/urls.txt
> +++ b/Documentation/urls.txt
> @@ -36,6 +36,29 @@ To sync with a local directory, you can use:
>  - file:///path/to/repo.git/
>  ===============================================================
>  
> +If there are a large number of similarly-named remote repositories and
> +you want to use a different format for them (such that the URLs you
> +use will be rewritten into URLs that work), you can create a
> +configuration section of the form:
> +
> +------------
> +	[host "<host>"]
> +		base = <actual url base>
> +		alias = <other url base>
> +------------
> +
> +In particular, if you need to use URLs like
> +git://git.host.xz/repo.git, and you're getting a lot of URLs like
> +host.xz:/path/to/repo.git/, or you'd like to use a URL like
> +"work:repo.git" you can use a section:
> +
> +------------
> +	[host "host.xz"]
> +		base = git://git.host.xz/
> +		alias = host.xz:/path/to/
> +		alias = work:
> +------------
> +

Could you _finish_ that documentation with finished example of command line example, which gets its URL rewritten? It stops a bit suddenly.

-- 
Jakub Narebski
Poland
Previous: Daniel Barkalow
Message 10 of 10 in “Add support for host aliases in config files”
  1. Add support for host aliases in config filesDaniel Barkalow, Jan 25, 2008
  2. Jakub NarebskiJan 25, 2008
  3. Junio C HamanoJan 25, 2008
  4. Daniel BarkalowJan 25, 2008
  5. Jakub NarebskiJan 25, 2008
  6. Daniel BarkalowJan 25, 2008
  7. Jakub NarebskiJan 25, 2008
  8. Junio C HamanoJan 25, 2008
  9. Daniel BarkalowJan 25, 2008
  10. Jakub NarebskiJan 25, 2008

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.