Size: 6302
Comment:
|
Size: 6418
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 9: | Line 9: |
Please send a request to support@ee.ethz.ch with the name of the repository you wish to have. We will create the repository and send you the access credentials. You can then add coworkers by your own through http://svnmgr.ee.ethz.ch/. | --(Please send a request to support@ee.ethz.ch with the name of the repository you wish to have. We will create the repository and send you the access credentials. You can then add coworkers by your own through http://svnmgr.ee.ethz.ch/.)-- We don't actually create new SVN repositories anymore. Please use Git on https://git.ee.ethz.ch. instead. |
Contents
Subversion Overview
We are running an Subversion server at svn.ee.ethz.ch.
To use Subversion you will need most of the time the svn command which is installed on all of our UNIX platforms. On Windows we suggest using TortoiseSVN, also available in our Windows Environment.
Requesting a Subversion Repository
Please send a request to support@ee.ethz.ch with the name of the repository you wish to have. We will create the repository and send you the access credentials. You can then add coworkers by your own through http://svnmgr.ee.ethz.ch/.)-- We don't actually create new SVN repositories anymore. Please use Git on https://git.ee.ethz.ch. instead.
When you have got a repository you can begin with these steps to start with your project: user@hostname:~>mkdir myproj Make first contact with the svn server, you will be asked to enter your password, which will be saved in a hidden .svn folder so you won't be asked anymore. There is the .svn folder in which Subversion stores settings like the project repository, server and so on. An example of this (not the best way, but just to show how it would work): Note that here you do not create the subdirectories yourself, Subversion does it for you as defined on the server and the system adds necessary information in the .svn subdirectory too.
user@hostname:~>cp ~/perl/*.pl trunk To let Subversion know that there are new files which need to be stored centrally, do the following: The 'A' stands for added (to Subversion).
Before editing files, you should always do a svn update to get the latest revision of the files. Note: Revision 5 is a set for the repository tree (for ALL the files) even if the only difference between revision 4 and 5 is in the file admin_portal.pl.
To remove a badly tagged version you can do this too directly server: To have a look which taged versions are available: 12. To move whole branches from one place in the repository to another:
This above were just basic steps to show you the concept behind Subversion. We recommend you to read the reference book called Version control with Subversion
After logging in on a Solaris-machine, execute the following command:
GNOME keyring is locked and we are non-interactive Checking Out the Repository
user@hostname:~>svn checkout https://svn.ee.ethz.ch/myproj
Authentication realm: myproj
Password for 'muster':
Checked out revision 0.
user@hostname:~>ls -lA myproj
total 8
drwxr-xr-x 7 muster myproj 512 May 27 18:11 .svn/
cd myproj
mkdir trunk tags releases
svn add trunk tags releases
user@hostname:~>cd myproj
user@hostname:~>svn mkdir trunk tags releases
user@hostname:~>svn checkout https://svn.ee.ethz.ch/myproj
A myproj/trunk
A myproj/revisions
A myproj/tags
Adding Files To Your Repository
user@hostname:~>cd trunk
user@hostname:~>svn add *
A admin_portal.pl
A adv_reg_portal.pl
A assign_to_reviewer.pl
A assign_to_tc.pl
A attendees.pl
A build_sessions.pl
A change_cont_pass.pl
A change_rev_pass.pl
A change_tc_pass.pl
...
user@hostname:~>svn commit -m "Saving the first version" #-m is the comment for this revision
Adding trunk
Adding trunk/admin_portal.pl
Adding trunk/adv_reg_portal.pl
Adding trunk/assign_to_reviewer.pl
Adding trunk/assign_to_tc.pl
Adding trunk/attendees.pl
Adding trunk/build_sessions.pl
Adding trunk/change_cont_pass.pl
Adding trunk/change_rev_pass.pl
Adding trunk/change_tc_pass.pl
Transmitting file data ..............................................
Committed revision 1.
Deleting Files From Your Repository
user@hostname:~>rm -r trunk
user@hostname:~>svn checkout https://svn.ee.ethz.ch/myproj/trunk/
A trunk/logadmin.pl
A trunk/submit_paper.pl
A trunk/enroll.pl
A trunk/include
A trunk/include/header_one.inc
...
Checked out revision 4.
user@hostname:~>vim trunk/admin_portal.pl
user@hostname:~>svn commit -m "saving admin_portal.pl" trunk
Sending trunk/admin_portal.pl
Transmitting file data ...
Committed revision 5.
Generating Tags In A Repository
#as a first important step, check-in all changed files of the trunk
user@hostname:~>svn commit -m "pretagging commit" trunk
#then do the tagging directly on the server
user@hostname:~>svn copy -m "tagging version release-1.0" https://svn.ee.ethz.ch/myproj/trunk \ https://svn.ee.ethz.ch/myproj/tags/release-1.0;
user@hostname:~>svn rm https://svn.ee.ethz.ch/myproj/tags/badlytaggedversion
user@hostname:~>svn ls https://svn.ee.ethz.ch/myproj/tags/
user@hostname:~>svn mv https://svn.ee.ethz.ch/myproj/trunk/test/subdir https://svn.ee.ethz.ch/myproj/trunk/plan/
Further Steps
Migrating a CVS to a Subversion Repository
usr/pack/subversion-1.2.1-rp/cvs2svn/cvs2svn --create -s $URL_OF_NEW_SVN_REPO $URL_OF_OLD_CVS_REPO
Known Problems