cvs配置

1 安装cvs
#rpm -ih cvs-xx-xx-xx(xx是版本号)

或者是#apt-get install cvs

或者直接在网上找cvs的源码,自己编译安装

2 添加cvs组
#groupadd cvs

3 添加cvsroot
#useradd -g cvs -G cvs cvsroot (需要指定目录时在后面加-d /xxx)
#passwd cvsroot (设置cvsroot账号密码)

4 更改默认cvs代码目录(/home/cvsroot)属性
#su cvsroot
#chmod 771 /home/cvsroot
#su root

5 添加cvs组用户
#useradd -g cvs cvsuser1
#useradd -g cvs cvsuser2
#passwd cvsuser1
#passwd cvsuser2
(按照具体情况和要求添加CVS用户)
#vi /etc/group (modify)
cvs:x:105:cvsroot,cvsuser,cvsuser1

6 添加cvspserver配置文件

注意:这一步骤要求系统安装有xinetd.d服务,ubuntu下为apt-get install xinetd.d
#cd /etc/xinetd.d
#vi cvspserver

# cd /etc/xinetd.d
#vi cvspserver
service cvspserver
{
socket_type = stream
protocol = tcp
wait = no
user = root
passenv =
server = /usr/bin/cvs
server_args = --allow-root=/home/cvsroot pserver
log_on_success +=USERID
log_on_failure +=USERID
disable =no
}

#vim /etc/services (add line)
cvspserver 2401/tcp #CVS client/server Operation
cvspserver 2401/udp #CVS client/server Operation

7 开启服务
#su root
#cd /home/cvsroot
#cvs init
#/etc/rc.d/init.d/xinetd restart
#cvs -d:pserver:cvsuser1@localhost:/home/cvsroot login (cvsuser1只是一个例子)
password:******
 
8 确定没有问题后,设置环境变量
#vi /etc/profile
添加
export CVSROOT=:pserver:$USER@localhost:/home/cvsroot

9 正常登陆
#cvs login
cvsuser password:******

10 导入项目
cvsroot 登陆
#cvs login
#cd /to/project_dir/ (进入代码所在目录第一层)
#cvs import -m "write some comments here" project_name vendor_tag release_tag

11 项目导出
#cvsuser登陆
#cvs login
#cvs co project_name

转载于:https://www.cnblogs.com/centimeter/archive/2011/02/20/1959284.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值