Where to start with source-control
Asked Answered
F

29

20

Anyone have any suggestions on where to start for a newbie wanting to try out some sort of source-control along with a new journey into ASP.NET? SVN, VSS, CVS...I dont even know where to start!

Fivestar answered 19/9, 2008 at 15:43 Comment(0)
B
12

Lots of people here have suggested introductions and comprehensive how-tos, which are all good for telling you how to do what you want.

In addition, I'd give three pieces of advice for the novice on how to know what you want:

1) Version-control EVERYTHING (that is, everything you write).

Version-control the project files. Version-control your test cases. Version-control any little scripts you use to copy things around. Version-control your todo list. Definitely version control your design notes. Once you're familiar with the commands it costs nothing, and some day you'll be glad of the history of a file you'd never imagined needing to roll back.

2) When you're happy with a change, check it in immediately. And check it all in.

If you work in sequential steps (and that doesn't always happen - you can get distracted - but it's good practice), then at the start of each new step you should have 0 modified files in your checkout. You may even want to check in unfinished non-working code, depending on what suits you.

3) When you reach a milestone, tag it.

Even your own personal goals (inch-pebbles). If you can't be bothered with tagging, just make a note of the date and time (in, you guessed it, a version-controlled file). If a particular version is memorable for some reason ("I finished the back-end", "I sent it to someone else to look at"), you want to know exactly what was in it. And diffing against the repository diagnoses some kinds of bugs faster than the debugger.

Bakunin answered 19/9, 2008 at 16:21 Comment(0)
R
15

just make sure you stay away from visual source safe.

Rene answered 19/9, 2008 at 15:46 Comment(0)
H
14

Eric Sink's Source Control HOWTO.

Read it, then download Subversion (free) or Vault (free for a single user) and start playing around with it.

Hairbrush answered 19/9, 2008 at 15:44 Comment(2)
I wholly agree. That series was the definitive primer that got me to learn the concepts and the differences.Bumgarner
However, realize that subversion isn't the be-all end-all of source control. it's the most popular right now but is only one of many. Once you learn the basics take some time to look at alternatives so you aren't looking at the world through a peephole.Exoskeleton
B
12

Lots of people here have suggested introductions and comprehensive how-tos, which are all good for telling you how to do what you want.

In addition, I'd give three pieces of advice for the novice on how to know what you want:

1) Version-control EVERYTHING (that is, everything you write).

Version-control the project files. Version-control your test cases. Version-control any little scripts you use to copy things around. Version-control your todo list. Definitely version control your design notes. Once you're familiar with the commands it costs nothing, and some day you'll be glad of the history of a file you'd never imagined needing to roll back.

2) When you're happy with a change, check it in immediately. And check it all in.

If you work in sequential steps (and that doesn't always happen - you can get distracted - but it's good practice), then at the start of each new step you should have 0 modified files in your checkout. You may even want to check in unfinished non-working code, depending on what suits you.

3) When you reach a milestone, tag it.

Even your own personal goals (inch-pebbles). If you can't be bothered with tagging, just make a note of the date and time (in, you guessed it, a version-controlled file). If a particular version is memorable for some reason ("I finished the back-end", "I sent it to someone else to look at"), you want to know exactly what was in it. And diffing against the repository diagnoses some kinds of bugs faster than the debugger.

Bakunin answered 19/9, 2008 at 16:21 Comment(0)
F
8

Very Subversion specific but it gives a decent understanding of version control basics.

http://svnbook.red-bean.com/

Featherveined answered 19/9, 2008 at 15:45 Comment(0)
S
5

I think the easiest way is to get a free SVN server through some free provider. I use assembla.

Then, if you are in Windows, you should download TortoiseSVN. That is by far the easiest Subversion client to use.

Start by importing a current project into the repository and then you are ready to go.

Shalloon answered 19/9, 2008 at 15:51 Comment(1)
The easiest way is to issue svnadmin /svnRepo/proj1 ; svn import ~/proj1/ file:///svnRepo/proj1/trunk -m "good times"Outset
T
3

I reccomend SVN to start off with, bit easier to get the hang of than some others.

Tortoise is a good start. It's simple to install and integrates with the windows shell, meaning everything is fairly intuitive on Right-clicks on folders / files etc. Pretty good doc as well.

You will also need a SVN server / host to connet to... I can reccomend Assembla which is free to register with and gives you a SVN server to play with.

Tetrapterous answered 19/9, 2008 at 15:52 Comment(2)
Dammit - in the time it took me to retype my answer after accidentally navigating away, someone beat me to the exact same post!Tetrapterous
I think someone new to version control should start with command line tools to get a feel for what is actually happening on disk. If you learn by just clicking on icons it will all just seem like so much magic.Exoskeleton
C
3

I will recommend Subversion or Visual Studio Team Foundation Systems depending on how much money you are willing to shell out.

Check out Visual SVN (Subversion for die-hard VS fans) - it integrates nicely with Visual Studio: http://www.visualsvn.com/

Connotative answered 19/9, 2008 at 15:55 Comment(0)
S
2

If you are just getting started, I would recommend reading through the free Subversion book. It is a widely-used system, free, and should be relatively easy to comprehend once you get going.

Singletree answered 19/9, 2008 at 15:45 Comment(0)
I
2

If you're 100% .NET, and you have an MSDN developer license, run TFS for Workgroups. Its pretty simple and solid.

If you don't have a license, check out Subversion. Its a nice, free source control that has plugins for Visual Studio integration.

Ingratiating answered 19/9, 2008 at 15:45 Comment(0)
T
2

I first got introduced to svn using tortoise svn, loved it and later a company used Visual Sourcesafe, how I missed using tortoise.

Timothytimour answered 19/9, 2008 at 15:46 Comment(0)
F
2

Get a copy of the book Pragmatic Version Control Using Subversion - it will help you get started.

Image http://ecx.images-amazon.com/images/I/51XYQTP2BYL._SL500_AA240_.jpg

Flour answered 19/9, 2008 at 15:47 Comment(2)
Nice tip. Edited to add book image.Valorous
I have that book. It's not as good as the free online book at svnbook.red-bean.com.Subchloride
R
2

Since nobody has mentioned this yet, I'd recommend looking at Git as well. There's even a free source hosting service: github.

Reagent answered 19/9, 2008 at 15:58 Comment(0)
G
2

Nowadays I would just start with a distributed system. They are easier to set up (you don't need to set up a server and/or find one on-line: just init some random directory and start doing your stuff) and just as easy/hard to understand as the centralized ones.

Here are a few that people should take a look when choosing a distributed revision control system:

If you're stuck in Windows, I would stay away from Git (at least for the time being). There seems to be support for Git on Windows in progress, but I haven't tried it yet.

Gull answered 19/9, 2008 at 16:39 Comment(0)
A
1

Have to second reading the Subversion book. Plus, the software is free, runs on most environments, and is easy to get going.

Androus answered 19/9, 2008 at 15:46 Comment(0)
P
1

The Pragmatic series has two of the best books I have read to help get your head around version control. They have versions for SVN and CVS. I really like their chapters on tags and branches.

Piper answered 19/9, 2008 at 15:50 Comment(0)
T
1

What source control to use really depends on your environment, your corporate culture and the general situation of how projects are handled in your company. The newer "Visual Source Safe" in Team Foundation is hands down better than the piece of crud that VSS used to be. and is good in a Microsoft shop with one or few locations. I've also used Subversion very successfully, and it integrates well into Eclipse. I don't like to put down products, since all have their positive and negative points, I guess. But the two I mentioned above are really good source/version control products. If you are just getting started and want to get your feet wet and learn source control practices and general concepts, download an open source product like CVS or Subversion, load it up and try it out.

http://www.ericsink.com/scm/source_control.html has some good information to work with.

-- I am re-editing this comment to note that it looks like someone else linked to that source control link in a previous post. :) darn it, I wasn't the first to post it.

Tertial answered 19/9, 2008 at 16:5 Comment(0)
V
1

Just getting tools installed is not enough. You need to understand how the particular technology works (like SVN) and how the whole source tree supposed to work: best structure, tagging, branching, merging and so fourth. Since we use SVN I recommend Subversion Book. It has some good explanations of source control concepts.

Vespertine answered 19/9, 2008 at 16:6 Comment(0)
H
1

Check out Subversion (SVN) to start. As suggested in other posts, there's an excellent free ebook that not only covers how to use SVN but is an excellent start on the concepts.

For an easy to setup server, check out the free server from VisualSVN.

If you use Visual Studio, you can use their add-in (costs) or the open source Ankh SVN addin. If you're using other IDEs, Tortoise SVN integrates with Explorer in Windows.

Halmahera answered 19/9, 2008 at 16:13 Comment(0)
T
1

Start with Subversion. The documentation is online, and the Pragmatic Programmers Svn book is great.

If you're on Windows you can also get TortoiseSvn (free) for explorer integration or VisualSvn (commercial) for Visual Studio integration. For the Mac, Versions looks like a nice stand alone client, and XCode 3 has svn integration built in. Still I'd spend a bit of time in the command line using the svn client to really figure out what you're doing.

After getting comfortable with the way svn works, then you can get into distributed version control systems like Git, Bazaar, or Mercurial, but I've seen enough professional developers have problems wrapping their heads around the basics of version control (branching merging etc) that I'd get comfortable with that first before moving to distributed systems.

Stay the hell away from Visual SourceSafe (VSS). It is poop. Your code is not safe. See these many links as to why not to use VSS.

Tortosa answered 19/9, 2008 at 17:24 Comment(0)
M
1

subversion ftw.

Mcnair answered 19/9, 2008 at 18:51 Comment(1)
I’ve lost more time to Subversion than to any other piece of software I use. It is just barely fit for purpose -- better than the likes of CVS, which is unusable -- but otherwise hopeless.Incised
W
0

You could start browsing through this site.

https://stackoverflow.com/questions/tagged/source-control

Watanabe answered 19/9, 2008 at 15:46 Comment(0)
P
0

In my opinion if you already have Viual Source Safe and you are a single developer doing work with VS, it is perfectly fine. Its a simple system that works well enough for small single developer projects. I have used it for years without any trouble for small projects. Easy to manage and backup as well.

Parsifal answered 19/9, 2008 at 15:53 Comment(0)
U
0

I believe that strating point is with Distributed version control system (like mercurial or git). There are some advandtages of using it :

  1. You don't need to setup central repository (it rquires tedious server setup)
  2. You can share changesets (revisions) with your friends by using email or other method, and integrate changes to your repository safely.
  3. You can modify revision history (rebase, git supports it) easilly, what is impossible to do with SVN.
Undressed answered 19/9, 2008 at 15:55 Comment(1)
Just to mention that SVN doesn't require tedious server setup for a one-person project - all you need is a local repository, which takes one command to create. You can publish it later. That's not to say git isn't better in the other ways you mention.Bakunin
Q
0

I recommended trying on of the free distributed version control systems. Most of them are very easy to setup on your personal PC and come with good documentation. Here are my favourites 1. Bazaar 2. Mercurial 3. Git (only for *nix based systems as far as I know)

See a list here:

http://en.wikipedia.org/wiki/List_of_revision_control_software

Queensland answered 19/9, 2008 at 16:11 Comment(0)
L
0

Comments on products that I've used:

VSS - Haven't used it in a while now (several years), at the time it did the basics of what we wanted but we were running into a variety of issues regularly enough that we actively sought out a better solution. If you've got free access then it wouldn't hurt to get exposure to their implementation to see what was at the time a different way of dealing with the issues (they may have come into line with the rest of the products by now).

CVS - Used this at a previous company, and worked with the original author of tortoiseCVS so I'm a little biased perhaps in thinking that it was a decent open source solution. I'd recommend starting here personally, everythings easily available and widely used.

Perforce - Our companies current source control solution and pretty much universally well regarded on the team. A couple of alternative UI's that people can choose between and good command line support too (vital for tools interaction). If you're evaluating for a company I'd certainly include this in your list to look at.

Lacielacing answered 19/9, 2008 at 16:43 Comment(0)
O
0

Try Unfuddle for a free hosted SVN source control.

Octarchy answered 19/9, 2008 at 18:48 Comment(0)
S
0

Another vote for Subversion / TortoiseSVN but note that it doesn't play nicely with a FAT32 domestic NAS.

Sweetbrier answered 19/9, 2008 at 18:50 Comment(0)
O
0

I've been losing faith to the whole source control community. Everyone is saying VSS is hell bad, likes those old bias, C++ is way better than C, Win Vista is terrible and XP is too old to serve the world. Yet still lots of people using them. You never know how you would like a tool before you use it. And every version control application consists of bugs and defects. And VSS is just so difficult to drop.

Oscular answered 17/6, 2011 at 9:38 Comment(0)
H
-2

Visual Source Safe (VSS) is fine for a beginner, because you won't know what you're missing. When you need something more complicated, then worry about getting some other product.

Harrus answered 19/9, 2008 at 16:26 Comment(5)
No, it isn't. VSS eats projects and it's archaic. Don't teach the poor noob bad habits.Rene
eats projects, hmm, Archaic, hmm, darn, thats where all my projects went to. Thanks for the peice of advice. Oh wait, look there they are. Nice and neat and tidy and version controlled for years. Dont be an idiot and implying that something is just 'bad' with no context and calling people noobs.Parsifal
@mattlant- look up at the top of the thread, where I included the link to "VSS considered Harmful": codinghorror.com/blog/archives/000660.html . I didn't call Gary a noob, I said not to teach noobs (like the OP, who described himself that way) bad habits. Maybe the idiot is you.Rene
Never had any problem with VSS.Harrus
I think it depends on the needs. For local team and small projects, I think VSS is good. But VSS does have many weaknesses, like database easy to corrupt in some cases, poor remote performance etc. For SourceSafe users, you may try SourceAnywhere. It uses SQL Server as back-end and has interface similar to VSS.Matelot

© 2022 - 2024 — McMap. All rights reserved.