Quick start
- For now, I have this all working via the command line. There are some UI tools, but they cost money or don't seem to work, and I don't want to spend the time on them.
- You must be connected to the VPN
- Just to try it out, open a shell (Terminal). John, you can try this on the Linux box or wait for your Mac. I don't have it set up for Windows (though it could be)
- I have a test project called 'Sandbox' that we can play with
- At a command line, type
svn checkout svn://10.8.0.1/sandbox. It appears that once you have done the checkout, you don't have to specify the host again. Note: you ALWAYS want to be in the top level directory under which you want the file tree to be made. For instance, if you want to work with /var/www/sandbox, you would first change to the /var/www directory, then do the checkout. This applies to both the initial and later checkups. This caught MattWalsh by surprise, because you're likely in some other directory messing around and wanting to refresh your files. It will happily create a new tree in whatever directory you're in.
- You should see that a few files (including A and B) under a folder 'sandbox' have been xferred to your machine.
- Note, unlike other source packages, you do not have to 'lock' a file first. You can just go to town on these files right away. Edit one of the files and save it
- To check in all change(s) (because all changed files are checked in at once) type:
svn commit -m "some comment". You will see that the files have gotten submitted to the server.
- Someone else, if they wanted those changes, would do another
svn checkout svn://10.8.0.1/sandbox operation. But let's say that while you were editing your file blah, some other guy edited the same file, and he does the checkout. Subversion will recognize the problem, and you will see files 'blah' (with a diff in it), a.rx (for the last checked in rev 'x') and a.ry (for the most recent checkin rev 'y'). It's up to you decide what to do. But the checkin won't work until you remove all the extra temp files.
- Say you want to add a file
foo. Just do svn add foo. Now that doesn't add the file UNTIL you do your next commit as described above.
Handy command line invocations
To get started, you probably want to get the latest source off the server, then find the diffs from your current stuff, then check those in. To find what files are different, move your
main directory to
main_now (or similar). Then, from your
~/Sites/snapsell/www directory run:
diff -qr main main_now | grep -v \.svn
See also
- This guide on normal usage
- This intro is a great conceptual overview on how it works
- JohnYates read 1/2 of the first one and all of the second one. Sounds like an awesome tool and I'll be happy to use it. I will read more of the instructions when I actually start using it...otherwise it won't stick. Sounds great! I would like to have some slightly more gui tool with it, but we can discuss
--
MattWalsh - 20 Feb 2007