2013-06-24 154 views
2

我想在CentOs 6.3上安装Mercurial 2.2,但是我觉得centos的存储库有点过时,因为它的yum安装总是显示你的mercurial是最新的。在Centos上安装Mercurial 6

现在搜索一些论坛,发现了一些其他的资料库,通过使用下面的命令和存储库更新善变的客户:

**

rpm -Uvh http://pkgs.repoforge.org/mercurial/mercurial-2.2.2-1.el6.rfx.i686.rpm

**

但是它会导致以下错误:

hg = 1.4-3.el6 is needed by (installed) emacs-mercurial-1.4-3.el6.i686

hg = 1.4-3.el6 is needed by (installed) mercurial-hgk-1.4-3.el6.i686

我觉得由于一些软件包依赖,我无法安装。

任何帮助/指针将不胜感激。

回答

0

我认为您需要卸载较旧的(1.4.3)版本的Mercurial。或者至少首先摆脱emacs-mercurial和mercurial-hgk软件包。

5

从博客:Install Mercurial Centos 6 VPS Mercurial 2.2.2 Centos 6.4 setup

This the only package you're able to install because other RPM packages require python 2.4 whereas Centos 6 has python 2.6 installed.

rpm -Uvh http://pkgs.repoforge.org/mercurial/mercurial-2.2.2-1.el6.rfx.x86_64.rpm 

测试您的安装:

[[email protected]~]# hg version 
Mercurial Distributed SCM (version 2.2.2) 
(see http://mercurial.selenic.com for more information) 

Copyright (C) 2005-2012 Matt Mackall and others 
This is free software; see the source for copying conditions. There is NO 
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 
+0

遵循本指南[使用Yum安装Mercurial Linux .rpm文件](https://www.mercurial-scm.org/wiki/Download#Linux_.28.rpm.29)也适用于最新的Hg 3.9版本。 –

0
echo -e "[mercurial.selenic.com]\nname=mercurial.selenic.com\nbaseurl=https://www.mercurial-scm.org/release/centos\$releasever\nenabled=1\ngpgcheck=0" > /etc/yum.repos.d/mercurial.selenic.com.repo \ 
&& yum install -y mercurial 

如上所述in the mercurial wiki。虽然,如gpgcheck=0是一种邪恶,我会尽可能跳过它。