0


git pull 报错 could not read from remote repository解决

git pull 报错

remote: Your account has been blocked.

fatal: could not read from remote repository。一般是SSH的形式clone的仓库,权限被更改了。

如下步骤解决:

重新 生成 gitLabKey 并应用:

     step 1:     使用命令 ssh-keygen -t rsa -b 2048 -C "[email protected]"
     
     step 2:     出现这一句的时候 Enter file in which to save the key (/c/Users/lvl/.ssh/id_rsa):直接回车
                 然后输入gitLab密码        Enter passphrase (empty for no passphrase):
                 输入之后回车
                 再次出入相同的gitLab密码   Enter same passphrase again:
                 之后就回车,完成这一步。
     
     step 3:     执行 ssh-agent bash 命令 回车稍等一下就ok了。
     
     step 4:     接着执行 ssh-add ~/.ssh/id_rsa 命令。提示输入gitLab密码。输入结束,回车完成这一步。会生成对应的sshKey数据放到相应的目录下。这个命令执行之后会将目录显示出来。
     
     step 5:     找到对应目录下的 /ssh/id_rsa.pub文件,将里面的字符串 copy 到 gitLab setting 里面的 SSH Keys 对应的文本框内,点击Add就ok了。
     
     step 6:     注意,第一次 git clone的时候,需要输入 gitLab密码。

————————————————
版权声明:本文为CSDN博主「含影」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/vily_lei/article/details/108847399

标签: git github ssh

本文转载自: https://blog.csdn.net/vily_lei/article/details/130391987
版权归原作者 含影 所有, 如有侵权,请联系我们删除。

“git pull 报错 could not read from remote repository解决”的评论:

还没有评论