GIT 上传文件出错:fatal: Could not read from remote repository. 解决方案
问题
git push -u origin master 执行后报错
fatal: Could not read from remote repository.
解决方案
1. git执行
git remote add origin git@github.com:username/xxx.git
2. 打开.ssh文件夹
找到 id_rsa.pub 文件
3. 打开GitHub的设置Settings
选择SSH KEYS设置,点击New SSH key按钮
用记事本打开 id_rsa.pub 文件将内容全部复制到Github的key中然后点击 add ssh key 按钮,即可。
others:
如果错误未能解决,尝试重置ssh key
ssh-keygen -t rsa -C "github账号"
1. 打开 .shh 文件夹,新生成的id_rsa、id_rsa.pub两个文件及新的Key
2. 打开github的Settings,设置ssh key(重复上述添加new SSH key步骤即可)
GIT 上传文件出错:fatal: Could not read from remote repository. 解决方案的更多相关文章
- git上传文件出错的时候
$ git pull --rebase origin master 运行这个基本OK!
- git上传文件夹的问题
使用git上传文件夹一定要注意,文件夹里面至少有一个文件,因为git不能管理空文件夹 所以上传就会不成功
- git clone ssh 时出现 fatal: Could not read from remote repository
一.问题及解决办法参考: 在 ubuntu 中,要把 GitHub 上的储存库克隆到计算机上时,执行如下命令: git clone git@github.com:USER-NAME/REPOSITOR ...
- Git上传文件
最近开始折腾node.js,顺便学习了Git上传的相关知识,找了许多关于Git如何上传项目的相关资料,最终发现一篇比较简易完整的文章, 在此分享一下喜悦的心情!下文是使用Git上传的完整教程: 将文件 ...
- 【bug】----- Git上传文件错误导致本地代码丢失
1.问题描述:通过Git上传本地文件,在git commit操作后本地未上传的代码全部丢失... 2.解决: 第一步:在项目目录下打开Git Bash: 第二步:输入 git reflog 第三步:在 ...
- git上传文件到coding
一.上传文件到coding:1.远程连接coding,下载远程仓库到本地git clone https://git.coding.net/wanghao_1/besttest_syz.git 2.cd ...
- 使用Git上传文件到github
第一次利用git连接github时往往都不会勾选Initialize this repository with a README,这样的的确确是简单了,但是如果我们需要勾选,勾选了之后应该怎么办呢?1 ...
- 使用GIT上传文件,VSCODE使用GIT上传项目
GIT使用方法: 1.安装git 2.设置用户名和邮箱: git config --global user.name="haokan1113" git config --globa ...
- git上传文件夹报错: ! [rejected] master -> master (fetch first) error: failed to push some refs to 'https://github.com/taminachen/rjxm.git' hint: Updates were rejected because the remote contains work
使用git上传本地文件夹到远程仓库,使用如下命令:git push -u origin master时报错 原因是在GitHub创建仓库时创建了readme文件,但是本地没有这个文件,造成本地目录与远 ...
- 新手使用GIT 上传文件到github
手把手教你如何使用 Git # 初始化一个新的Git仓库 1.方式一: mkdir(make directory) test或者直接进入文件夹中再打开git 方式二:cd /文件夹 cd(change ...
随机推荐
- Java面向对象之类与对象的创建
类与对象的创建 类是一种抽象的数据类型,它是对某一类事物整体描述/定义,但是并不能代表某一个具体的事物. 1.动物.植物.手机.电脑..... 2.Person类.Pet类.Cat类等,这些类都是用来 ...
- ubuntu下升级gcc11环境
使用ppa源升级 官网地址: https://launchpad.net/ ppa toolchan/test地址: https://launchpad.net/~ubuntu-toolchain-r ...
- Xrdp服务安装配置实现Linux远程桌面访问以及问题处理
0x00 基础介绍 0x01 安装桌面环境 Ubuntu 系列 0x02 Xrdp 安装使用 How to Install xrdp on Ubuntu ? How to Install xrdp t ...
- pve apt 更新
解决pve6.2/pve6.3 安装ifupdown2,失败问题 https://www.cnblogs.com/lovesKey/p/14400874.html https://blog.whsir ...
- 记录VUE项目使用 sass 版本不匹配问题
之前安装的node.js 是16 版本的导致找不到合适node sass 版本. node.js 退版本之后正常 -------------------------------------- ---- ...
- WPF 使用Path(自定义控件,圆形进度条)
原文:https://www.cnblogs.com/tsliwei/p/5609035.html 原文链接:https://blog.csdn.net/johnsuna/article/detail ...
- docker登录Ubuntu出现error storing credentials - err: exit status 1, out: `Cannot autolaunch D-Bus without X11 $DISPLAY`的解决方法
命令行登录docker时,在Ubuntu 18.04下可能会出现 error storing credentials - err: exit status 1, out: `Cannot autola ...
- Java pom阿里云插件
<pluginRepositories> <pluginRepository> <id>alimaven spring plugin</id> < ...
- echarts柱状图快速上手笔记地址
https://blog.csdn.net/qq_40323256/article/details/114890628 借鉴借鉴
- 最小化安装debian10&gnome最小化安装
直到后面配置网络源之前都是断网安装,因为debian security好像总是要去总源找点东西,所以即便你选择国内源甚至不选择网络源安装,依然会莫名 的失败. I. 最小化安装debian10(用ro ...