As soon as you tell me who your partner is, I will make a repository
for you.
It will be found in /cslab/class/cs335/
[your names]/projrepos
,
where "your names" is your two first names, one word lower case, alphabetized by
last name.
For example, Jan Schreur and Dawson Toth's group is in the jandawson
repository.
I will also start a blank project for you, which each partner should checkout.
svn checkout file:///cslab/class/cs335/XXXXX/projrepos/proj1
where XXXXX
is your names.
To use svn to track your project, use the following commands.
Thing.java
,
open and save it as you normally would,
and then tell svn about it with
svn add Thing.java
things
, don't just make it,
but let svn make it for you:
svn mkdir things
svn
+ unix command).
svn commit -m "The doStuff() method in thing.Thing was reading out of bounds. Fixed it."
svn update
If you have made changes to a file that has also changed in the
repository,
svn will try to merge them, but need you to figure out how to resolve any
conflicts.
If there are conflicts in a file (say, Thing.java
),
you will see four files as a result:
Thing.java.r14 Thing.java.r18 Thing.java.mine Thing.java
Thing.java.r14
is the restored file you last updated
before doing your changes.
In this case, we're assuming you had updated to revision 14, and
then started making your changes.
Meanwhile, there have been 4 more commits to the repository,
and now the latest version is revision 18.
That's contained in the file Thing.java.r18
.
Thing.java.mine
contains the file as you had it (with your changes)
before you did this update.
The file Thing.java
contains a merged version;
in any case where a section of the files Thing.java.r19
and Thing.java.mine
differ, it
will show both versions, annotated so you you know which is which.
What you must do before going on is resolve the conflicts---figure out
what Thing.java
should be in light of the difference between
your version and the repository version.
Fix Thing.java
up and delete the other files.
Svn has many more features than I've described here. It wouldn't be a bad idea to peruse the svn manual.