push到github时,每次都要输入用户名和密码的问题
2015-04-14 09:37
567 查看
问题
在github.com上 建立了一个小项目,可是在每次push 的时候,都要输入用户名和密码,很是麻烦原因
原因是使用了https方式 push这种方式产生的原因,一般是我们clone是一定是使用了http的方式
例如我们在github上创建了一个项目,然后我们clone到本地时使用了http而非git
我们可以看到右端的项目地址,默认是http的,clone时
git clone https://github.com/gatieme/AderSCloud.git[/code]
如果使用ssh的话,应该使用的路径是git clone git://github.com/gatieme/AderSCloud.git解决
在termail里边 输入git remote -v
可以看到形如一下的返回结果origin git@github.com:gatieme/AderSCloud.git (fetch) origin git@github.com:gatieme/AderSCloud.git (push)
下面把它换成ssh方式的。
移出旧的http的origingit remote rm origin
添加新的git方式的origin
git remote add origin git@github.com:gatieme/AderSCloud.git
我们在查看一下push方式git remote -v再次push一下,已经不需要输入用户名密码了 git push origin
相关文章推荐
- github常遇问题 push到github时,每次都要输入用户名和密码的问题
- push代码到github时,每次都要输入用户名和密码的问题
- push到github时,每次都要输入用户名和密码的问题
- push到github时,每次都要输入用户名和密码的问题
- push到github时,每次都要输入用户名和密码的问题
- push到github时,每次都要输入用户名和密码的问题
- push代码到github时,每次都要输入用户名和密码的问题
- push到github时,每次都要输入用户名和密码的问题
- push到github时,每次都要输入用户名和密码的问题
- 本地 push 到github 每次都需要输入用户密码问题
- git push的时候每次都要输入用户名和密码的问题解决
- 最新如何解决git 输入github时每次都要输入用户名和密码问题
- Git本地仓库push至GitHub远程仓库每次输入账户密码问题解决
- git push的时候每次都要输入用户名和密码的问题解决
- [转]git push的时候每次都要输入用户名和密码的问题解决
- Github:每次git push推送的时候都需要输入git的用户名和密码
- 解决tortoiseGit每次push都需要输入用户名密码的问题
- push代码到github每次输入用户名和密码
- git push的时候每次都要输入用户名和密码的问题解决
- 解决git指令更新远程仓库github时每次都要输入用户名和密码问题