Subversion : Install2015/07/13 |
Install Subversion which is the revision control tool.
|
|
[1] | Install Subversion. |
[root@dlp ~]# yum -y install subversion
|
[2] | Create a repository. For example, create "/var/svn/repos/project" on here. |
[root@dlp ~]# mkdir -p /var/svn/repos/project [root@dlp ~]# svnadmin create /var/svn/repos/project [root@dlp ~]# svn mkdir file:///var/svn/repos/project/trunk -m "create" Committed revision 1. [root@dlp ~]# svn mkdir file:///var/svn/repos/project/branches -m "create" Committed revision 2. [root@dlp ~]# svn mkdir file:///var/svn/repos/project/tags -m "create" Committed revision 3. |
[3] | If some development files exist yet, it's possible to import it to a repository. For example, import files under "/home/project" into the repository of above. |
[root@dlp ~]# svn import /home/project file:///var/svn/repos/project/trunk -m "initial import" Adding /home/project/count.cgi Adding /home/project/index.html Adding /home/project/main.php Committed revision 4. # confirm [root@dlp ~]# svn list file:///var/svn/repos/project/trunk count.cgi index.html main.php |
[4] | It's possible to access from other clients to run svnserve. svnserve listens on 3690/TCP, so allow it on firewalls on the network. |
# access from a client (read only by default) [cent@client ~]$ svn list svn://dlp.srv.world/repos/project branches/ tags/ trunk/ # check out [cent@client ~]$ svn checkout svn://dlp.srv.world/repos/project A project/tags A project/trunk A project/trunk/count.cgi A project/trunk/index.html A project/trunk/main.php A project/branches Checked out revision 4. |
[5] | It's possible to access with SSH without svnserve. If you would not like to allow 3690/TCP or use authentication algorithm by SSH, use this way. |
[root@dlp ~]#
systemctl stop svnserve # access from a client with SSH [cent@client ~]$ svn list svn+ssh://cent@dlp.srv.world/var/svn/repos/project cent@dlp.srv.world's password: branches/ tags/ trunk/ |
Sponsored Link |