我已经使用Git一段时间了,但是不断要求输入密码开始让我感到困惑.
我正在使用OSX和Github,我按照GitHub的Set Up Git页面的指示设置了Git和我的SSH密钥 .我还在我的Mac OSX钥匙串中添加了github SSH密钥,如GitHub的SSH密钥密码页面所述.我的公钥是在Git注册的.
不过,每次我尝试git pull,我都要输入我的用户名和密码.我需要为此设置除SSH密钥以外的其他东西吗?
我一直在使用Github上一小会儿,我一直罚款git add,git commit以及git push到目前为止,没有任何问题.突然间我有一个错误说:
致命:身份验证失败
在终端我克隆了一个存储库,处理了一个文件然后我用来git add将文件添加到提交日志中,当我这样做时git commit,它运行正常.最后,git push要求输入用户名和密码.我正确地把它们放进去,每次我这样做,它都说同样的错误.
有谁知道这个问题的原因是什么以及我如何解决它?
内容.git/config是:
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[remote "origin"]
url = http://www.github.com/######/Random-Python-Tests
fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
remote = origin
merge = refs/heads/master
[user]
name = #####
email = ############
Run Code Online (Sandbox Code Playgroud) 我被困在防火墙后面,所以必须使用HTTPS来访问我的GitHub存储库.我在Windows XP上使用cygwin 1.7.7.
我已经尝试将遥控器设置为https://username@github.com/username/ExcelANT.git,但是提示输入密码,但是一旦我输入密码就没有做任何事情.
https://username:<password>github.com/username/ExcelANT.git并从头开始克隆空仓库,但每次它给我同样的错误
错误:SSL证书问题,验证CA证书是否正常.详细信息:
错误:14090086:SSL例程:SSL3_GET_SERVER_CERTIFICATE:访问https时出现证书验证失败:https://github.com/username/ExcelANT.git/info/refs
打开GIT_CURL_VERBOSE=1给我
*关于connect()到github.com端口443(#0)
*尝试207.97.227.239 ...*成功设置证书验证位置:
*CAfile:无
CApath:/ usr/ssl/certs
*SSL证书问题,验证CA证书没问题.详细信息:
错误:14090086:SSL例程:SSL3_GET_SERVER_CERTIFICATE:证书验证失败
*过期已清除
*关闭连接#0
*关于连接()到github.com端口443(#0)
*尝试207.97.227.239 ...*成功设置证书验证位置:
*CAfile:无
CApath:/ usr/ssl/certs
*SSL证书问题,验证CA证书是否正常.细节:
错误:14090086:SSL例程:SSL3_GET_SERVER_CERTIFICATE:证书验证失败
*过期已清除
*关闭连接#0
错误:SSL证书问题,验证CA证书是否正常.详细信息:
错误:14090086:SSL例程:SSL3_GET_SERVER_CERTIFICATE:访问https时出现证书验证失败:https://github.com/username/ExcelANT.git/info/refs
fatal: HTTP request failed
Run Code Online (Sandbox Code Playgroud)
这是我的防火墙,cygwin还是什么问题?
我没有在Git配置中设置HTTP代理,但是它是一个需要NTLM身份验证的ISA服务器,而不是基本身份,所以除非有人知道如何强制git使用NTLM,否则我会被打破.
我在GitHub上有一个公共存储库.我想复制/复制它并处理基于此存储库的新项目,但我不想影响它现在的状态.我尝试使用GitHub UI进行分叉,但它没有做任何事情.
我做了什么:我在Github上创建了一个远程存储库,我正在尝试克隆本地计算机上的远程存储库.克隆时我正在提供克隆URL和目标文件夹.
但每次我尝试克隆时,我都会收到此错误:
错误:"致命:无法访问' https://github.com/hyperion057/spring-repo.git/ ':无法解析主机:github.com"
连接到GitHub需要做什么?
有没有办法安全地让git在通过HTTP(S)连接到远程存储库时记住我的凭据?
我已经尝试了core.askpass详细介绍的方法git-config,让外部脚本提供我的凭据.虽然它工作得很好,但用户名和密码仍然以纯文本形式存储在小shell脚本中.
我正在使用Git将更改推送到通过HTTP/WebDAV共享的存储库,Git会提示输入访问HTTP远程的每个操作的密码.有没有办法让Git缓存密码/让远程服务器不提示我?
远程Web服务器应该是Apache,如果需要,可以重新配置.
我还在浏览一些关于RoR的指南,我在这里部署演示应用程序
我按照说明:
完成Microposts资源后,现在是将存储库推送到GitHub的好时机:
Run Code Online (Sandbox Code Playgroud)$ git add . $ git commit -a -m "Done with the demo app" $ git push
这里发生的错误是推动部分......它输出了这个:
$ git push
fatal: No configured push destination.
Either specify the URL from the command-line or configure a remote repository using
git remote add <name> <url>
git push <name>
Run Code Online (Sandbox Code Playgroud)
所以我尝试按照说明执行此命令:
$ git remote add demo_app 'www.github.com/levelone/demo_app'
fatal: remote demo_app already exists.
Run Code Online (Sandbox Code Playgroud)
所以我推:
$ git push demo_app
fatal: 'www.github.com/levelone/demo_app' does not appear to be a git repository
fatal: The …Run Code Online (Sandbox Code Playgroud) Dunno发生了什么事,没有github对此问题的回应所以我在这里问.在一个月左右的时间里第一次尝试了一个git push并得到了这个.打开导出GIT_CURL_VERBOSE = 1并进行推送并获取此信息:
localhost:send2mobile_rails phil$ git push
Password:
* Couldn't find host github.com in the .netrc file; using defaults
* About to connect() to github.com port 443 (#0)
* Trying 207.97.227.239... * Connected to github.com (207.97.227.239) port 443 (#0)
* SSL connection using DHE-RSA-AES256-SHA
* Server certificate:
* subject: O=*.github.com; OU=Domain Control Validated; CN=*.github.com
* start date: 2009-12-11 05:02:36 GMT
* expire date: 2014-12-11 05:02:36 GMT
* subjectAltName: github.com matched
* issuer: C=US; ST=Arizona; L=Scottsdale; O=GoDaddy.com, Inc.; OU=http://certificates.godaddy.com/repository; CN=Go …Run Code Online (Sandbox Code Playgroud) 我试图从我的本地存储库将文件推送到我的远程存储库,我看到了这一点
致命错误:致命:无法访问' https://github.com/vinivasundharan/abcd.git/ ':无法解析主机'github.com'
我的计算机没有使用任何代理,因为我已经看到了在使用代理时解决问题的方法.
我试过这个和这个的解决方案.但两者似乎都没有帮助.我的系统使用Windows 7进行了有效的Internet连接.
UPDATE
git config -l返回以下内容.我不得不发布它,因为我没有这意味着什么exaclty
core.symlinks=false
core.autocrlf=true
color.diff=auto
color.status=auto
color.branch=auto
color.interactive=true
help.format=html
http.sslcainfo=C:/Users/vav9sw/AppData/Local/Programs/Git/mingw64/ssl/certs/ca-bundle.crt
diff.astextplain.textconv=astextplain
rebase.autosquash=true
user.name=xyz
user.email=xyz@gmail.com
core.repositoryformatversion=0
core.filemode=false
core.bare=false
core.logallrefupdates=true
core.symlinks=false
core.ignorecase=true
core.hidedotfiles=dotGitOnly
remote.origin.url=https://github.com/vinivasundharan/abcd.git
remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*`
Run Code Online (Sandbox Code Playgroud)
编辑
只是为了确保我已按照上传文件到GitHub的步骤检查附加图像以查看我所遵循的步骤.