解决一下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解决的

相关内容

热门资讯

透视模拟器!aapoker俱乐... 透视模拟器!aapoker俱乐部靠谱吗,来玩德州破解器(详细辅助2025新版总结)1、点击下载安装,...
透视教学!wpk透视表,wpk... 透视教学!wpk透视表,wpk软件是真的吗,透明挂教程(切实真的是有挂)1、玩家可以在wpk透视表软...
wepoker底牌透视脚本ht... wepoker底牌透视脚本http!pokemmo辅助器手机版下载,aapoker透视怎么用(详细辅...
透视透视“aapoker透视脚... 透视透视“aapoker透视脚本下载”果然有挂(辅助挂)详细辅助揭秘教程运辅助工具,进入游戏界面。进...
透视智能ai!wejoker私... 透视智能ai!wejoker私人辅助软件,黑科技辅助软件免费(都是是真的有挂)1、游戏颠覆性的策略玩...
透视科技!wepoker底牌透... 透视科技!wepoker底牌透视脚本,wpk是真的还是假的(详细辅助高科技教程)1、很好的工具软件,...
wepoker透视脚本网页!竞... wepoker透视脚本网页!竞技联盟透视,hhpoker透视方法(详细辅助安装教程)是一款可以让一直...
透视玄学!智星菠萝辅助,智星德... 透视玄学!智星菠萝辅助,智星德州插件,透明教程(切实是有挂)1、上手简单,内置详细流程视频教学,新手...
透视挂透视“wpk辅助插件叫什... 透视挂透视“wpk辅助插件叫什么”真是真的有挂(辅助挂)详细辅助安装教程;1、超多福利:超高返利,海...
透视好友!红龙poker有辅助... 透视好友!红龙poker有辅助吗,微友联盟有辅助吗(一直是真的有挂)1、首先打开微友联盟有辅助吗最新...