git lfs pull in repository会产生关于拨号tcp的错误

问题描述 投票:1回答:1

存储库中的git lfs pull会产生以下错误:

oobarbazanoo @ LAPTOP-CQEVT11F MINGW64 / c / Projects / doesnotmatter / ecom-oneapp-data-staging / ecom-oneapp-data-staging(master)$ git lfs pull

批处理响应:post https://[email protected]/doesnotmatter/ecom-oneapp-data-staging.git/info/lfs/objects/batch:proxyconnect tcp:dial tcp:lookup helloInternet:没有这样的主机批处理响应:post https://[email protected]/doesnotmatter/ecom-oneapp-data-staging.git/info/lfs/objects/batch:proxyconnect tcp:dial tcp:lookup helloInternet:no such host batch response:post https://[email protected]/doesnotmatter/ecom-oneapp-data-staging.git/info/lfs/objects/batch:proxyconnect tcp:dial tcp:lookup helloInternet :没有这样的主机批处理响应:post https://[email protected]/doesnotmatter/ecom-oneapp-data-staging.git/info/lfs/objects/batch:proxyconnect tcp:dial tcp:lookup helloInternet:no host host batch response:post https://[email protected]/doesnotmatter/ecom-oneapp-data-staging.git/info/lfs/objects/batch:proxyconnect tcp:dial tcp:lookup helloInternet:no host host batch response:post https://[email protected]/doesnotmatter/ecom-oneapp-data-staging.git/info/lfs/objects/batch:proxyconnect tcp:dial tcp:lookup helloInternet:没有这样的主机...

似乎问题是关于代理以错误的方式配置。所以,我决定尝试再次运行命令git config --global --unset http.proxy然后运行git lfs pull。它没有帮助,我得到了与上面相同的错误。

我使用的是Windows 10.以下是C:\Windows\System32\drivers\etc\hosts.file文件的副本:

# Copyright (c) 1993-2009 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
#      102.54.94.97     rhino.acme.com          # source server
#       38.25.63.10     x.acme.com              # x client host

# localhost name resolution is handled within DNS itself.
#   127.0.0.1       localhost
#   ::1             localhost

如您所见,其中没有指定helloInternet主机。实际上该文件是完全空白的,因为它只包含注释。

我该怎么做才能解决这个问题?

所以,这是我的环境变量:enter image description here

删除http_proxy变量并尝试命令后,一切正常。

git tcp proxy git-lfs
1个回答
0
投票

Go和大多数处理代理的其他工具都支持多个环境变量来控制所使用的代理。对于HTTP,这是http_proxy环境变量,对于HTTPS,请参阅http_proxyhttps_proxy

看起来您可能在您的环境中设置了其中一个或两个;取消它们可能会帮助您直接连接到服务器。

© www.soinside.com 2019 - 2024. All rights reserved.