git-remote: support remotes with a dot in the name

[jc: the original from Pavel was limiting the variable names to only
 fetch and url, but I loosened it to take valid variable names.]
[jc: cherry-picked from 'master', since people seem to be reinventing
 this many times.]

Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Pavel Roskin 2007-02-21 00:03:36 -05:00 коммит произвёл Junio C Hamano
Родитель c5ddca1fff
Коммит 4e5104c1fc
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -67,7 +67,7 @@ sub list_remote {
$git->command(qw(config --get-regexp), '^remote\.');
};
for (@remotes) {
if (/^remote\.([^.]*)\.(\S*)\s+(.*)$/) {
if (/^remote\.(\S+?)\.([^.\s]+)\s+(.*)$/) {
add_remote_config(\%seen, $1, $2, $3);
}
}