TDDD26 Development of Interactive Systems
SVN
The version control system offered in the course is Subversion (SVN). Use is optional!
A version control system is a tool for keeping track of history and successive versions of documents, applications, etc., so that you can go back and see who did what, compare versions, go back to a previous version, etc. The different versions of a document is saved in a version archive (repository). An archive per project group has been created.
Adding module SVN
In order to use SVN, you must add the module for SVN. However, check first if you already have SVN module installed, by issuing the following command in a terminal window:
svn helpIf the answer is "svn: Command not found", you must add the SVN module. Either you can give the command in each terminal window where you want to use SVN:
module add prog / subversion
or you can give the following command in a terminal window:
module initadd prog / subversion
and after you have been logged out once, SVN will automatically be available in all the terminal windows you open.
Identify the SVN Repository
To find the centrally-created SVN archives, visit the following link: https://svn-und.ida.liu.se/courses/TDDD26/2012-1-PROj/groupname groupname is Group1, Group2 or Group3.
To verify the link, give the command:
svn list https://svn-und.ida.liu.se/courses/TDDD26/2012-1-PROJ/groupname
Save the link to the SVN Repository
It is convenient to save the link to an SVN repository in an environment variable. If you intend to use the central SVN repository for TDDD26 you can create an environment variable, here named SVNTDDD26, with the command:
setenv SVNTDDD26 https://svn-und.ida.liu.se/courses/TDDD26/2012-1-PROJ/groupname
Add the command in your file ~/.cshrc.private, so that the variable is set every time you open a new terminal window.
Importing source files to the SVN Repository
To add the original files to an SVN repository you use a command in the following form:
svn import /home/xxxxx000/TDDD26/proj/source/ $SVNTDDD26 -m "original TDDD26 project source"
Note, this command may take some time ...
Check out a working copy from SVN Repository
Every time you wnat to make changes to a file, you must check out a copy from the SVN repository. An example of a command that checks out a file directory dir with the files and subdirectories are:
svn checkout $ SVNTDDD26/dir dirchmod og-rwx dirCD dirset-svn-ignore
When you give more SVN commands, do it in a terminal connected to the checked-out file directory dir, since SVN then knows what was checked out.
Save changes to the SVN Repository
Every time you make a successful change, you should save (commit) in the SVN repository, as well as before any major proposed changes to be made. Then you can later compare the different versions, such as when troubleshooting. You save in the following form, if done in a terminal connected to the checked-out file directory:
svn-m "message" commit
Other SVN commands
To see the change history (commit-history):
svn upsvn log
To see all changes since the Revision rev:
syn diff -x -wup -r rev
Information on what you can do with SVN:
svn help
Information on a specific subcommand:
svn help subcommand
Page responsible: Annika Silvervarg
Last updated: 2012-03-14
