Topic: Subversion

Hi All. I've tried installing and running subversion but to no avail.

Im not one of those people who are very comfortable reading/understanding Unix type tutorials and I find that more information on subversion is written under the assumption that the person reading it is a total geek.

Have any of you come across instructions for installing, running and using subversion that are simple and easy to follow?

Re: Subversion

What platform are you on? For most platforms there's a package that you can just run to install subversion. Then it's just a matter of learning how the subversion commands work. There's the online book for that.

Railscasts - Free Ruby on Rails Screencasts

Re: Subversion

ryanb wrote:

What platform are you on? For most platforms there's a package that you can just run to install subversion. Then it's just a matter of learning how the subversion commands work. There's the online book for that.

I'm using XP Pro & OS X - I have no real problem installing subversion - but because instructions are crappy and full of stuff that is totally meaningless (i.e. makes no sense) to me I find it difficult to even use it correctly. No offense - but I tried referring to that book and to me it may as well be written in Greek - even the quick start guide at the end assumes you know a hell of a lot - what ever happened to plain, basic English. sad

Once I figure it out I'm going to write my own tutorial for the rest of us big_smile

Last edited by Bink (2007-05-22 16:23:08)

Re: Subversion

Bink wrote:
ryanb wrote:

What platform are you on? For most platforms there's a package that you can just run to install subversion. Then it's just a matter of learning how the subversion commands work. There's the online book for that.

I'm using XP Pro & OS X - I have no real problem installing subversion - but because instructions are crappy and full of stuff that is totally meaningless (i.e. makes no sense) to me I find it difficult to even use it correctly. No offense - but I tried referring to that book and to me it may as well be written in Greek - even the quick start guide at the end assumes you know a hell of a lot - what ever happened to plain, basic English. sad

Once I figure it out I'm going to write my own tutorial for the rest of us big_smile

I, for one, would be grateful if you did write a plain english tutorial for subversion big_smile

Re: Subversion

What is the problem? I never even read the subversion book and I use subversion pretty easily. I started with SVNX a client on OS X for it, but just recently I moved to the command-line version of it, and it's pretty much just as easy, or easier.

Once subversion is installed, you'll want to create a respository for all your code. I usually place mine in ~/projects/vc

vc for version control. And then each directory under is for a specific project, like ~/projects/vc/project1

Then project one usually has a trunk (latest development code), then tags and branches. I've never really used the tags and branches directory, but for practical use it should be a way to bookmark certain stages of code (like rails 1.2.3 would be a tag).

Then once you have a repository structure, you'll want to import your project into the trunk, and then walah you have a working subversion respository. From there you can check out your code (equivlant to downloading it), update your code, roll it back, etc.

Hope that helps!

http://danielfischer.com - Personal Web-Technology-Blog, Los Angeles.

Re: Subversion

This page should help you create a repository of your code, and also will show you how to add your project to it. A repository is where subversion stores all the copies of your code.

To make things easier we will use full paths in these commands. You can find the full path for the directory you are currently in by typing pwd

So lets say for instance you project is in /Users/dahuk/projects/ror/myproject

You want to create a repository lets say at /Users/dahuk/projects/svnrepos/myproject

Use the command (make sure the directory exists first)

svnadmin create /Users/dahuk/projects/svnrepos/myproject

Now you have an empty repository and you have to add your current code to it.

Change your current directory to /Users/dahuk/projects/ror

svn import myproject file:///Users/dahuk/projects/svnrepos/myproject -m "anything you want"
#The -m means message

Now your code should be in your repository. Next we need to create a working copy. Your working copy is the place where you will be making all of your changes and working on your project. Lets say you want to do your work at /Users/dahuk/myproject. Go to /Users/dahuk, then use the following command.

svn checkout file:///Users/dahuk/projects/svnrepos/myproject

You will notice it created a directory call myproject, change to it and now you should have a working working copy. Make a change to it, like edit the readme and then save.

Then type

svn status

You will see that subversion found the change. To save the changes to the repository type:

svn commit -m "wow we are on v2 now!"

There you go! Now if you go and read the basic functionality chapter it should be a lot easer to figure things out.
Let me know if you have any questions!

Also if you type svn help you can see all the possible commands.

Last edited by dahuk (2007-05-25 12:35:17)

Re: Subversion

I just released a railscasts episode on setting up a Rails project with subversion.

Railscasts - Free Ruby on Rails Screencasts

Re: Subversion

Excellent, thank you!

http://danielfischer.com - Personal Web-Technology-Blog, Los Angeles.

Re: Subversion

ryanb wrote:

I just released a railscasts episode on setting up a Rails project with subversion.

Excellent - Ive used different source control apps/tools many, many times in the past on enterprise level projects - its just that the Subversion instructions out there for some reason are impossible to follow for me.

Now I am beginning to get it smile

Re: Subversion

Hey question, does anyone know how I would add another user that is able to co/ci/etc... to a repository besides "deploy" part of capistrano and stuff? Let's call the new user "bob" smile

http://danielfischer.com - Personal Web-Technology-Blog, Los Angeles.

Re: Subversion

Well, to deploy bob needs SSH access to the production server. Can't you just not tell him the password?

Railscasts - Free Ruby on Rails Screencasts

Re: Subversion

Well, it's the fact that I want to know who did what revivion via subversion - not so much who deploys.

Otherwise it's "updated by deploy" on svn.

http://danielfischer.com - Personal Web-Technology-Blog, Los Angeles.