无法使用 Homebrew 安装 Git
我已经尝试在 OSX Lion 上使用 Homebrew 安装 Git 一个多星期了,但没有成功。其他安装都很好,请问我做错了什么?
MacBookPro:Rails pingu$ brew install git
==> Downloading http://kernel.org/pub/software/scm/git/git-1.7.6.1.tar.bz2
curl: (22) The requested URL returned error: 503
Error: Failure while executing: /usr/bin/curl -f#LA Homebrew\ 0.8\ (Ruby\ 1.8.7-249;\ Mac\ OS\ X\ 10.7) http://kernel.org/pub/software/scm/git/git-1.7.6.1.tar.bz2 -o /Users/pingu/Library/Caches/Homebrew/git-1.7.6.1.tar.bz2
I have been trying to install Git using Homebrew on OSX Lion for over a week now, with no luck. Other installs have been fine, what am I doing wrong please?
MacBookPro:Rails pingu$ brew install git
==> Downloading http://kernel.org/pub/software/scm/git/git-1.7.6.1.tar.bz2
curl: (22) The requested URL returned error: 503
Error: Failure while executing: /usr/bin/curl -f#LA Homebrew\ 0.8\ (Ruby\ 1.8.7-249;\ Mac\ OS\ X\ 10.7) http://kernel.org/pub/software/scm/git/git-1.7.6.1.tar.bz2 -o /Users/pingu/Library/Caches/Homebrew/git-1.7.6.1.tar.bz2
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
如果您点击“brew install git”发出的链接 - 您会发现该网站“已关闭以进行维护”。这就是为什么它不起作用!
一位聪明的 SO'er 通过使用 tar 镜像找到了这个问题的解决方案。 您可以阅读此答案中的说明
If you follow the link that 'brew install git' spits out - you will find that the website is "Down for maintenance". That's why it is not working!
A clever SO'er found the solution to this problem by using a mirror for the tar. You can read his instructions in this answer
如果您自己访问 URL,您将请注意巨大的维护警告。这可能与最近的 有关kernel.org 上的安全漏洞。
请稍后在 kernel.org 管理员确定系统已保存后重试。
If you go to the URL yourself you will notice the huge Maintenance warning. This is probably connected with the recent security breach on kernel.org.
Just try again later when the kernel.org admins are sure that the systems are save.
值得保留一个主要状态代码的图表,以便方便使用。一个很好的来源是 https://en.wikipedia.org/wiki/List_of_HTTP_status_codes
404 是众所周知的足够了,但是 500 系列,如所示,反映了服务器问题。优秀的 Web 开发人员还应该查看他们的日志,例如,如果他们从现在不再使用的位置的链接获得定期点击,他们应该返回“301”(永久移动),这可能会触发引用链接器更新其链接(或不更新)。
It is worth keeping a chart of the major status codes, handy. A good source is https://en.wikipedia.org/wiki/List_of_HTTP_status_codes
404's are well known enough, but the 500 series, as indicated, reflect a server problem. Good web developers should also be looking at their logs, and if, for example, they are getting regular hits from a link to a location that they now no longer use, they should return a '301' (Moved Permanently), which may trigger the referring linker to update their link (or not).