我已经完成了文档所说的内容,当我输入时 ssh -T git@github.com,它会显示出来
Warning: Permanently added the RSA host key for IP address '[192.30.252.149]:443
' to the list of known hosts.
Hi fifiteen82726! You've successfully authenticated, but GitHub does not provide
shell access.
Run Code Online (Sandbox Code Playgroud)
但是,当我想推送一些东西时github,它仍然需要我username和password.为什么?
这是我的 .git/config
[core]
repositoryformatversion = 0
filemode = false
bare = false
logallrefupdates = true
symlinks = false
ignorecase = true
hideDotFiles = dotGitOnly
[remote "origin"]
url = https://github.com/fifiteen82726/MFA.git
fetch = +refs/heads/*:refs/remotes/origin/*
Run Code Online (Sandbox Code Playgroud)
您使用的是HTTPS协议而不是SSH.
将存储库的URL更改为 git@github.com:fifiteen82726/MFA.git
防爆.命令git remote set-url origin git@github.com:fifiteen82726/MFA.git
这是GitHub帮助页面,描述了如何获取不同协议的地址https://help.github.com/articles/which-remote-url-should-i-use/
| 归档时间: |
|
| 查看次数: |
297 次 |
| 最近记录: |