关闭

git 的一个权限问题

标签: git
252人阅读 评论(0) 收藏 举报
分类:

应该也不至于是权限问题

错误提示如下

fatal: 'origin' 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.

一个解决方法:

Elvis@ELVIS-PC /f/gitrepo/TestJedis (master)
$ git remote add origin git@gitserver:TestRedis.git
Elvis@ELVIS-PC /f/gitrepo/TestJedis (master)
$ git push origin master
ssh: gitserver: no address associated with name
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
Elvis@ELVIS-PC /f/gitrepo/TestJedis (master)
$ git remote set-url origin git@github.com:afredlyj/TestRedis.git
Elvis@ELVIS-PC /f/gitrepo/TestJedis (master)
$ git push origin master
Enter passphrase for key '/c/Users/Elvis/.ssh/id_rsa':
Counting objects: 8, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (7/7), done.
Writing objects: 100% (7/7), 2.07 KiB, done.
Total 7 (delta 2), reused 0 (delta 0)
To git@github.com:afredlyj/TestRedis.git
   7bcfb1a..b02a2fe  master -> master
Elvis@ELVIS-PC /f/gitrepo/TestJedis (master)

感谢网友

0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:77673次
    • 积分:1650
    • 等级:
    • 排名:千里之外
    • 原创:91篇
    • 转载:33篇
    • 译文:2篇
    • 评论:3条
    文章分类