真正做起来开发工作,才发现一台CVS服务器是必不可少的,即使是很少的开发人员的项目,使用CVS也会起到很大的作用,具体什么作用,大家去体会:)
下面把我架设CVS服务器的过程说说,和诸位前辈的不同之处在于我架设了一个WEB界面,所以说是"友好的",通过WEB界面可以非常直观的浏览代码,查看图形化的修改记录,(提交可以log到MySQL数据库--This feature is a clone of the Mozilla Projects Bonsai database.),目前SourceForge正在使用此界面的较低版本.
功能简介: 1:Base CVS Server; 2:repository browsing. 3:SQL checkin database. 4:Colorize sourcecode. 5:Can display a clickable, graphical of files in a CVS repository. 6:generate tarball from a repository on the fly.
OK,Lets go!
1:初始化环境
#groupadd cvs
#mkdir /home2/cvsroot #useradd -g cvs -G cvs -d /home2/cvsroot cvsroot
#su - cvsroot $chmod 775 .
OK!
2:启动CVS Server 诸位大虾已经有了很精辟的说明,拿来是了!:P
#more /etc/services|grep cvspserver cvspserver 2401/tcp # CVS client/server operations cvspserver 2401/udp # CVS client/server operations
OK,RedHat系统不傻,可以写脚本了.
#vi /etc/xinetd.d/cvspserver service cvspserver { disable = no flags = REUSE socket_type = stream wait = no user = root server = /usr/bin/cvs server_args = -f --allow-root=/home2/cvsroot pserver log_on_failure += USERID }
:wq
#ls /etc/xinetd.d/cvspserver /etc/xinetd.d/cvspserver
脚本好了!
#su - cvsroot $cvs -d /home2/cvsroot init #service xinetd restart
看看有没有?
#netstat -l |grep cvspserver tcp 0 0 *:cvspserver *:* LISTEN
Great!
3:Add a Web Interface,viewcvs-0.9.2
URL:http://viewcvs.sourceforge.net/
要求比较个性,很多很多!列表:
a: Python 1.5 or later(http://www.python.org/) Rh7.2竟然有两个python,1.5和2.1,更加有个性! b: RCS, Revision Control System(http://www.cs.purdue.edu/homes/trinkle/RCS/) Rh7.2自带. c: read-only, physical aclearcase/" target="_blank" >ccess to a CVS repository(See http://www.cvshome.org/ for more information) Rh7.2自带. d: a web server capable of running CGI programs(for example, Apache at http://httpd.apache.org/) viewcvs-0.9.2文档竟然说apache是可选项