解决一下git clone失败的问题
创始人
2025-01-10 09:05:26
0

1).不开梯子,我们用https克隆

git clone https://github.com

报错:

Failed to connect to github.com port 443 after 2091 ms: Couldn't connect to server
解决办法:

开梯子,然后# 注意修改成自己的IP和端口号
git config --global http.proxy http://127.0.0.1:7890 
git config --global https.proxy http://127.0.0.1:7890
然后报错
remote: Repository not found.
fatal: repository 'https://github.co    not found
解决办法
git clone http://token名字:token的值@github.com/用户名/仓库.git
然后我这里突然翻墙了访问不了github了,包括huggingface等等网站

然后我改了下clash和电脑本机代理的端口号,就可以了
然后你要记得修改
git config --global http.proxy http://127.0.0.1:7891
git config --global https.proxy http://127.0.0.1:7891
然后我git clone http://github-private:github_pat_11A6PKn@github.com
报错remote: Repository not found.
fatal: Authentication failed for 'http://github.com/hlx11/ss1.git/'
然后我又用了我同事的token试了一下,依旧不行,我真的裂开
2)ssh尝试

那重新来一遍吧
重新配置key

ssh-keygen -t ed25519 -C "your_email@example.com"

然后复制id_ed25519.pub里面的东西

然后我们git clone git@github.com:lx1/sun01.git 
报错ssh: connect to host github.com port 22: Connection refused
fatal: Could not read from remote repository.

然后我们输入ssh -T git@github.com
发现Bad owner or permissions on C:\\Users\\lzt/.ssh/config
然后经过删除config之后

报错ssh: connect to host github.com port 22: Connection refused

3)突然再次尝试https,这次将http改为了https
git clone https://github-private:github_pat_11A6PKOQI0I69C55fd2wwRodMdPn6xgrGWUwT34n0WrBj6B225NCIAvuPBuLMu@github.com/lxhlx11/supe
报错remote: Write access to repository not granted.
fatal: unable to access 'https://github.com/lxhl01/': The requested URL returned error: 403

还是不行,但是我感觉快成功了

于是我用我同事(创建者的token)试了一下,终于成功了

远程分支创建后,本地与之关联
git checkout -b cxh origin/cxh

然后就可以快乐的提交代码啦
所以最后还是用https解决的

相关内容

热门资讯

wpk有透视辅助!wpk俱乐部... 您好,这款游戏可以开挂的,确实是有挂的,需要了解加微【136704302】很多玩家在这款游戏中打牌都...
十分钟实锤!德州之星有外挂(德... 十分钟实锤!德州之星有外挂(德州俱乐部)原来真的有挂(详细辅助切实教程);德州之星有外挂辅助器中分为...
微扑克系统发牌规律(微扑克)微... 微扑克系统发牌规律(微扑克)微扑克ai技术(透视)总是是真的有挂(详细辅助黑科技教程)1、进入到微扑...
wpk有辅助挂!wpk德州扑克... wpk有辅助挂!wpk德州扑克靠不靠谱(透视)外挂透视挂辅助代打(素来是真的有挂);支持多人共享记分...
微扑克辅助挂(微扑克)微扑克俱... 微扑克辅助挂(微扑克)微扑克俱乐部(透视)竟然是真的有挂(详细辅助技巧教程)该软件可以轻松地帮助玩家...
2分钟实锤!德扑之星有作弊(来... 2分钟实锤!德扑之星有作弊(来玩德州)好像是真的有挂(详细辅助解密教程)1、构建自己的德扑之星有作弊...
aapoker透明挂!aapo... aapoker透明挂!aapoker ai软件,(aapoker教程)本来是有挂(详细辅助力荐教程)...
wpk真的有外挂!wpk微扑克... wpk真的有外挂!wpk微扑克智能辅助(透视)外挂透视辅助器(原来真的是有挂);小薇(透视辅助)致您...
微扑克辅助器ios(微扑克)微... 微扑克辅助器ios(微扑克)微扑克真的有辅助吗(透视)原来是真的有挂(详细辅助专业教程)暗藏猫腻,小...
5分钟实锤!德扑之星有作弊(来... 5分钟实锤!德扑之星有作弊(来玩德州)总是是有挂(详细辅助曝光教程)1、德扑之星有作弊透视辅助简单,...