通过命令行将代理添加到git config中,而无需代理用户/代理pwd

时间:2019-02-20 14:26:19

标签: git

我在/git/.gitconfig

中定义了此代理
[http "https://dpl.tdk.com"]
    proxy = http://10.0.11.25:8080

但是当我执行git config --list

时却不会出现

我想手动添加它,但是我不知道该怎么做,因为我没有<username>:<password>

git config --global http.proxy http://<username>:<password>@10.0.14.15:8080

2 个答案:

答案 0 :(得分:1)

git config --global http.proxy http://10.0.14.15:8080

答案 1 :(得分:0)

您将要关闭:

git config --global http."https://dpl.tdk.com".proxy http://<username>:<password>@10.0.14.15:8080

对于<username><password>,请咨询您的网络管理员。