我有git版本1.7.4.1。并希望升级到1.8.4的最新稳定版本。
所以我尝试了sudo apt-get install git
git downloads page for Linux,但我得到了这个结果:
Reading package lists... Done
Building dependency tree
Reading state information... Done
git is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 91 not upgraded.
$ git --version
git version 1.7.4.1
我坚持使用git版本1.7.4.1!
我在Ubuntu 11.04上。
答案 0 :(得分:5)
这是因为Ubuntu尚未在其存储库中更新软件包。解决这个问题的唯一方法是从源代码编译,您可以从https://github.com/git/git下载。
答案 1 :(得分:1)
Git有Ubuntu PPA,提供最新版本。添加其中一个,您就可以安装它了。例如:
https://launchpad.net/~git-core/+archive/ppa
阅读“将此PPA添加到您的系统”信息,了解如何执行此操作。
答案 2 :(得分:1)
您应该至少将整个系统升级为raring:
http://packages.ubuntu.com/search?keywords=git-core
(如果您遵守打包版本。)
但无论如何,消息来源会更新鲜。