提交到github远程仓库遇到的问题

1.could not read from remote repository

  可能原因是没有将ssh 密匙添加到github,所以没有权限

  解决办法:

    1. ssh-keygen -C 'your@email.address' -t rsa

    2. 将第一步生成的rsa pub 添加github 中




2.fatal: remote origin already exists.
远程仓库主分支已经存在

解决办法:
    1.git remote rm origin
    2.git remote add origin git@github.com:xxxx/gitdemo.git
原文地址:https://www.cnblogs.com/Andy963/p/6131489.html