zoukankan      html  css  js  c++  java
  • Git推送到远程分支出错

    执行git push -u origin master

    fatal: 'git@github.com:qilinonline/git_test.git' does not appear to be a git repository fatal: Could not read from remote repository.

    Please make sure you have the correct access rights and the repository exists.

    原因:使用地址不对,这里采用了ssh地址,但是你没有添加ssh秘钥,所以无法连接远程仓库

    解决办法:

    1.使用https地址

    2.添加ssh秘钥

    1:生成秘钥:ssh-keygen -t rsa -C "你自己的邮箱"

    (这里不要设置密码,直接按回车就可以,以后更新就不需要密码)

    2: id_rsa 这个文件是你的私钥、id_rsa.pub是你的公共秘钥,用记事本打开文件id_rsa.pub,把里面的内容复制到github配置ssh

    3:添加私秘钥到ssh: ssh-add id_rsa(如果添加失败可以先执行命令ssh-agent bash,然后再次添加私秘钥。)

    4: 用ssh -T git@github.com 判断是否绑定成功。如果返回successfully 表示成功

    具体教程看我上一章。

  • 相关阅读:
    linux下activemq安装
    java 线程方法join
    创建线程池
    游标储存过程
    返回结果集的储存过程
    linux 安装 reids 出错解决问题
    IDEAL 集成 jFINAL 问题
    oracle 游标
    oracle procedures
    Linux下安装Tomcat服务器
  • 原文地址:https://www.cnblogs.com/zwdeblog/p/9725069.html
Copyright © 2011-2022 走看看