转载自

第一步、确认Git公钥/密钥是否生成:

1、 首先查看本地是否生成git密钥,一般在C盘home目录下:【C:你自己的home目录\.ssh】

第二步:添加Git密钥:

右键->Git base here(前提是已经安装GIt), 具体如何安装Git, 请自行安装

按顺序执行命令

1、git config --global user.name "名称" 添加用户名配置

2、git config --global user.email "git邮箱'' 添加git邮箱配置

3、ssh-keygen -t rsa -C "git邮箱" 根据git邮箱生成公钥密钥, 此步骤切记不要输入密码, 因为idea连接的时候不需要密码. 后续步骤直接回车, 具体请参考截图.

完成以上步骤后, 已经生成密钥。

第三步:Git添加公钥:

将.ssh 的id_rsa.pub文件用编辑器打开, 复制里面的内容添加到git的公钥配置

第四步:确认IDEA是否添加私钥:

File->setting->搜索SSH->选择private key 选择你的私钥文件

第五步:确认IDEA的Git配置是否是本地:

File ->setting->搜说git->修改SSH excutable 为Native(PS: 操作完如果还是不能提交可以按照第六步重启一下Idea)

最开始没有重启IDEA, 操作完还是不行, 后面重启了一下可以了. 但是后面为了验证是否需要重启IDEA切换了几次, 发现不重启也没问题. 所以如果按照以上步骤仍然没有效果可以重启一下IDEA试试。

第六步: 重启IDEA

以上步骤操作完成, 就可以使用IDEA正常提交代码了

搜索

复制

8、IDEA提交代码出现: Fetch failed fatal: Could not read from remote repository的更多相关文章

  1. Push failed: Failed with error: fatal: Could not read from remote repository.

    GitLab push远端,出现错误提示:Push failed: Failed with error: fatal: Could not read from remote repository. 原 ...

  2. gitlab 拉代码提示:Your Account has been blocked. fatal: Could not read from remote repository. 最佳解决方案

    今天在脚本服务器上拉取代码,突然发现拉不了代码了,提示: GitLab: Your account has been blocked. fatal: Could not read from remot ...

  3. 【git基础】Permission denied (publickey). fatal: Could not read from remote repository

    运行以下git命令的时候出现错误 git push -u origin master error The authenticity of host 'github.com (13.250.177.22 ...

  4. fatal:'origin' does not appear to be a git repository fatal:Could not read from remote repository

    天gitlab中遇到的问题: 当 git push origin branch_name时遇到报错如下: fatal:'origin' does not appear to be a git repo ...

  5. git pull 出错 fatal: Could not read from remote repository.Please make sure you have the correct access rights.and the repository exists.

    Warning: Permanently added the RSA host key for IP address '192.30.252.131' to the list of known hos ...

  6. git提示错误关于错误:ssh: Could not resolve hostname github.com: Name or service not known.fatal: Could not read from remote repository.

    关于 Git 使用中出现的错误 饥人谷_楠柒 关注 2016.11.02 15:33* 字数 746 阅读 3607评论 5喜欢 10赞赏 1 关于错误:ssh: Could not resolve ...

  7. Permission denied (publickey). fatal: Could not read from remote repository.

    博主在github上下载tiny face的的源代码的时候,遇到git clone命令为:git clone --recursive git@github.com:peiyunh/tiny.git 而 ...

  8. On branch master nothing to commit, working tree clean ERROR: Repository not found. fatal: Could not read from remote repository.

    将gitbash部署hexo到github:hexo deploy 报以下错误: Administrator@liu MINGW64 /Hexo $ hexo d INFO Deploying: gi ...

  9. github下载报错:Permission denied (publickey). fatal: Could not read from remote repository.

    Permission denied (publickey). fatal: Could not read from remote repository. 博主在github上下载tiny face的的 ...

随机推荐

  1. Docker | 数据持久化与数据共享

    数据持久化(安装MySQL) 参考另一篇Docker安装mysql: https://www.cnblogs.com/all-smile/p/16778376.html MySQL的数据持久化问题 # ...

  2. 『现学现忘』Git后悔药 — 32、revert撤销(一)

    目录 1.Git的三种后悔药 2.revert命令原理 3.revert命令的使用 (1)移除某次提交的修改 (2)revert命令说明 1.Git的三种后悔药 在Git中后悔药有三种:amend.r ...

  3. JavaScript基本语法(数组与JSON)

    5.数组 #①使用new关键字创建数组 // 1.创建数组对象 var arr01 = new Array(); // 2.压入数据 arr01.push("apple"); ar ...

  4. VS Code For Web 深入浅出 -- 进程间通信篇

    在上一篇中,我们一起分析了 VS Code 整体的代码架构,了解了 VS Code 是由前后端分离的方式开发的.且无论前端是基于 electron 还是 web,后端是本地还是云端,其调用方式并无不同 ...

  5. laravel 报错 AUTH` failed: ERR Client sent AUTH, but no password is set

    明明没有设置redis密码.访问时候却报错 在代码里面的databases.php 改成这样就可以了.predis新版也会有取不到passwor的时候.改成我截图那样也可以.他默认取的是default ...

  6. JUC(7)四大函数式接口

    文章目录 1.四大函数式接口(必须掌握) 1.1 function 1.2 Predicate 1.3 Consumer 1.4 Supplier 1.四大函数式接口(必须掌握) 1.lambda表达 ...

  7. Codeforces Round #816 (Div. 2)/CodeForces1715

    CodeForces1715 Crossmarket 解析: 题目大意 有一个 \(n \times m\) 的空间,Stanley 需要从左上角到右下角:Megan 则需要从左下角到右上角.两人可以 ...

  8. C# Linq 查询汇总

    分组取值.求和.计数 1 var resultlist = orderllist.GroupBy(oo => new { oo.Deptname, oo.Userid, oo.Username ...

  9. fake_useragent—Error occurred during loading data报错问题

    问题如下 解决方法: 在自己的临时文件下新建一个fake_useragent_0.1.11.json 把下面的文字复制进去 临时文件 直接输入cmd %temp% 即可进去 { "rando ...

  10. 论文笔记 - MetaICL: Learning to Learn In Context

    Motivation Facebook 的 MetaICL,牛逼就对了: 对 LM 针对 ICL 进行微调(而不是特定的任务): 去除了自然语言的 Template,使用更直接的方式,排除了 Temp ...