summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2008-03-02 15:11:19 -0800
committerLibravatar Junio C Hamano <gitster@pobox.com>2008-03-02 15:11:19 -0800
commitca132089d2c7628fb6bca59715ece342777bdaf0 (patch)
treeb5f9cc72e4863fc0478b2915b165716c9531bcbe
parentMerge branch 'jn/gitweb-grep' (diff)
parentgit-remote: do not complain on multiple URLs for a remote (diff)
downloadtgif-ca132089d2c7628fb6bca59715ece342777bdaf0.tar.xz
Merge branch 'jc/remote-multi-url'
* jc/remote-multi-url: git-remote: do not complain on multiple URLs for a remote
-rwxr-xr-xgit-remote.perl6
1 files changed, 3 insertions, 3 deletions
diff --git a/git-remote.perl b/git-remote.perl
index 5cd69513cf..b30ed734e7 100755
--- a/git-remote.perl
+++ b/git-remote.perl
@@ -7,10 +7,10 @@ my $git = Git->repository();
sub add_remote_config {
my ($hash, $name, $what, $value) = @_;
if ($what eq 'url') {
- if (exists $hash->{$name}{'URL'}) {
- print STDERR "Warning: more than one remote.$name.url\n";
+ # Having more than one is Ok -- it is used for push.
+ if (! exists $hash->{'URL'}) {
+ $hash->{$name}{'URL'} = $value;
}
- $hash->{$name}{'URL'} = $value;
}
elsif ($what eq 'fetch') {
$hash->{$name}{'FETCH'} ||= [];