DaqSvn: Difference between revisions
Jump to navigation
Jump to search
Line 20: | Line 20: | ||
=== Switch repository from svn: to https: === | === Switch repository from svn: to https: === | ||
TBW | |||
=== Convert CVS repository to SVN === | |||
TBW | TBW |
Revision as of 10:19, 17 May 2011
General information
The TRIUMF DAQ group is hosting SVN repositories for itself and other TRIUMF users and experiments on ladd00.triumf.ca, the main daq server machine. The SVN repositories are stored on a mirrored disk configuration and are backed up to the TRIUMF AMANDA backup storage system.
Access to the SVN repository is provided using Viewvc (web viewer), svn: access method (being phased out) and https: access methods.
Useful links
TBW
User instructions
Checkout from repository
For initial checkout, use username "svn", password "svn". For writing to the repository, the "svn commit" command will prompt for your username and password.
Setup the svn config file
TBW
Switch repository from svn: to https:
TBW
Convert CVS repository to SVN
TBW
SVN administration
Create an SVN repository called "vf48"
- login as root@ladd00
- cd /home/daqweb/svn
- svnadmin create vf48
- edit /etc/viewvc/viewcvs.conf, in "svn_roots", add "vf48: /home/daqweb/svn/vf48," (notice the trailing comma!), go to "http://ladd00.triumf.ca/viewcvs", you should see the "vf48" repository, it should be empty.
- chown -R daqweb.mirror vf48
- chmod -R u+wr,g+wr vf48
Enable svn: access (DO NOT DO THIS)
- cd vf48/conf
- edit "passwd", add users and their passwords (swear at the svn authors: passwords are entered in clear text)
- edit "svnserve.conf", uncomment "[general]", "anon-access = read" and "passwd-db = passwd". Uncomment the line "realm = " and make it read "realm = VF48 SVN repository"
- chmod a-r,u+r passwd
- repository is now ready for use.
Enable https: access
- login as root@ladd00
- cd /home/daqweb/svn
- add new repository to dav_accessfile: create new groups and usernames as needed. User "svn" (password "svn") should have read-only access
- add new users to dav_passwd using the htpasswd utility: htpasswd dav_passwd username (will prompt for password)
- file dav_group is not used
Convert plain directory to SVN
- read explanation of canonical repository structure at http://svnbook.red-bean.com/nightly/en/svn.branchmerge.maint.html
- cd directory_to_convert
- mkdir foo --- create an empty directory in svn
- cd foo
- svn import . https://ladd00.triumf.ca/svn/daqsvn/trunk/name_of_my_svn_directory -m "Create svn directory"
- cd ..
- rm -rf foo (we no longer need it)
- svn checkout https://ladd00.triumf.ca/svn/daqsvn/trunk/name_of_my_svn_directory . (notice the dot)
- svn status (shows all files with status '?' - not managed by svn)
- svn add Makefile *.h *.cxx
- svn commit
- go to http://ladd00.triumf.ca/viewcvs/daqsvn/trunk/name_of_my_svn_directory --- you should see your files there
Import stuff into the "trunk"
- read explanation of canonical repository structure at http://svnbook.red-bean.com/nightly/en/svn.branchmerge.maint.html
- cd directory_with_stuff
- svn import . https://ladd00.triumf.ca/svn/daqsvn/trunk/test11 -m "Test import"
- cd ..; mv directory_with_stuff obsolete
- svn checkout https://ladd00.triumf.ca/svn/daqsvn/trunk/test11
Import VF48 firmware into the "vendor" branch
- read http://svnbook.red-bean.com/en/1.1/ch07s05.html
- svn import VF48COL_V211 https://ladd00.triumf.ca/svn/vf48/vendor/VF48COL_V211 -m "Importing VF48COL_V211"
- svn import VF48FE_V_E_212b https://ladd00.triumf.ca/svn/vf48/vendor/VF48FE_V_E_212b -m "Importing VF48FE_V_E_212b"
- mkdir obsolete; mv VF48COL_V211 VF48FE_V_E_212b obsolete
- svn checkout https://ladd00.triumf.ca/svn/vf48/vendor/VF48COL_V211
- svn checkout https://ladd00.triumf.ca/svn/vf48/vendor/VF48FE_V_E_212b