setting git insteadof in command line

Viewed 3409

Because of the poor network connection. I built some git repository mirrors to open source software.

$ cat ~/.gitconfig

[url "git://127.0.0.1/chromiumos"]
    insteadOf = "https://chromium.googlesource.com"
[url "git://127.0.0.1/chromiumos"]
    insteadOf = "https://boringssl.googlesource.com"
[url "git://127.0.0.1/chromiumos"]
    insteadOf = "https://pdfium.googlesource.com"
[url "git://127.0.0.1/chromiumos"]
    insteadOf = "https://weave.googlesource.com"

I want to made such configuration by typing command line, so remove them first:

git config --global --unset url.git://127.0.0.1/chromiumos.insteadof

Then add them again:

git config --global url.git://127.0.0.1/chromiumos.insteadof https://boringssl.googlesource.com
git config --global url.git://127.0.0.1/chromiumos.insteadof https://chromium.googlesource.com
git config --global url.git://127.0.0.1/chromiumos.insteadof https://pdfium.googlesource.com
git config --global url.git://127.0.0.1/chromiumos.insteadof https://weave.googlesource.com

But the result is not what I expected, only one config is take effect:

$ git config -global -l

url.git://127.0.0.1/chromiumos.insteadof=https://weave.googlesource.com
1 Answers
Related