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

Re: [PATCH] git-remote: support remotes with a dot in the name

From
Junio C Hamano <junkio@cox.net>
Date
Feb 21, 2007, 05:21 UTC
Message-ID
<7vwt2ct79x.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<20070221050336.26431.46485.stgit@dv.roinet.com>
Pavel Roskin <proski@gnu.org> writes:
Show 6 quoted lines
> Ignore configuration data other that "url" and "fetch" for the remote. 
> We cannot process it to extract the remote name from it reliably. 
> Besides, a remote without "url" is currently invalid, so we are not
> missing anything.
>
> Signed-off-by: Pavel Roskin <proski@gnu.org>

I do not think we ever officially "supported" remotes with a dot in their names since $GIT_DIR/remotes/ or $GIT_DIR/branches days.

Show 5 quoted lines
>  	for (@remotes) {
> -		if (/^remote\.([^.]*)\.(\S*)\s+(.*)$/) {
> +		if (/^remote\.(\S*)\.(fetch|url)\s+(.*)$/) {
>  			add_remote_config(\%seen, $1, $2, $3);
>  		}

I do not strongly oppose to allowing it now, but I suspect this is probably less impact:

	if (/^remote\.(\S+?)\.([^.\s]+)\s+(.*)$/) {
        	...
	}

With this, we disallow whitespaces in remote names, but we leave the door open for supporting variables other than fetch and url by accepting the third token that matches any sequence of non-dot, non-whitespace letters.

Previous: Pavel RoskinNext: Pavel Roskin
Message 2 of 8 in “git-remote: support remotes with a dot in the name”
  1. git-remote: support remotes with a dot in the namePavel Roskin, Feb 21, 2007
  2. Junio C HamanoFeb 21, 2007
  3. Pavel RoskinFeb 21, 2007
  4. Junio C HamanoFeb 21, 2007
  5. Pavel RoskinFeb 21, 2007
  6. Shawn O. PearceFeb 21, 2007
  7. Junio C HamanoFeb 21, 2007
  8. Theodore TsoFeb 21, 2007

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.