热搜:
下载Mercurial For Linux V3.5.1免费版

Mercurial For Linux V3.5.1免费版

更多
  • 软件大小:4.00MB (4,194,304 字节)
  • 软件类别:编程书集 -> 编程辅助
  • 软件授权:免费软件      软件语言:英文
  • 更新时间:2020/11/05
  • 软件厂商:
  • 软件官网:
  • 应用平台:
标签
软件介绍
热度:0

Mercurial For Linux是一种轻量级分布式版本控制系统,采用Python语言实现,易于学习和使用,扩展性强,其是基于GNU General Public License(GPL)授权的开源项目。这个工具在国内很少人使用,所以中文资料匮乏.只有官方的website上有一些少得可怜的中文资料了.不过总体上来说,还是比较好用的。

Linux下Mercurial(hg)配置说明

1.建立用户hgrepo

其它用户将用这个账户用hg服务器push代码。

useradd hgrepo -d /home/hgrepo # add user hgrepopasswd hgrepo

2.建立hg代码仓库

如果代码仓库名称为project.hg,则可用如下命令。

cd /home/hgrepomkdir project.hgcd project.hghg init # 初始化代码仓库建立一个测试文件

echo "hello, mercurial" > sample.txthg add # addhg ci # check in

3. 打开http

打开一个端口,让远程用户可以clone仓库中的代码.在打开端口前请确定文件权限正确。

更改文件权限chown hgrepo.hgrepo /home/hgrepo/project.hg -Rchmod og+rw /home/hgrepo/project.hg -R打开端口

cd /home/hgrepo/project.hg -Rhg serve -p 8002 &可将上面两行加入/etc/rc.local这样就可以在开机的时候自动运行了。

4.使用hg

完成步骤3以后,我们就可以使用了。

clone到本地

例如你的服务器的名字为test.

hg clonehttp://test:8002然后在本地目录就会出现一个project.hg的一个copy.

修改Client端的配置

更改.hg/hgrc,加上default-push和username

[paths]default =http://test:8002default-push = ssh://hgrepo@test//home/hgrepo/project.hg/[ui]username=shaohui.zheng这样你就可用hg push 向服务器提交code了。这时服务器会问你passward,这个password就是用户hgrepo的password.

Good Luck.

软件截图

  • Mercurial For Linux V3.5.1免费版第1张

下载地址

Mercurial For Linux V3.5.1免费版