码迷,mamicode.com
首页 > 其他好文 > 详细

初次配置git与github出现push不了的问题

时间:2016-07-02 13:11:20      阅读:123      评论:0      收藏:0      [点我收藏+]

标签:

ssh: connect to host gmail.com port 22: No route to host fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.

 在配置github为远程仓库是出现如上报错,具体有两个:

1.没有创建repository

2.防火墙拦截。如果已经FQ,那就要修改配置文件

修改配置文件:

a》打开终端,cd到本地仓库文件下;

b》运行git config --local -e,获取文件的路径,前往文件

c》打开文件,将文件中的url = git@github.com:username/仓库name.git 修改为url = https://username@github.com/username/仓库name.git

初次配置git与github出现push不了的问题

标签:

原文地址:http://www.cnblogs.com/IT-DavidYang/p/5635055.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!