I'm just learning how to do things, and want to start using some sort of version control for a web app.
What's most appropriate for deploying a python or php web app on my own? I'm using linux and have a linux server.
Thanks!
SVN, but you need to be able to easily deploy your webapp with SVN.
Since it is not always a simple task, so I just point out this article which may be of interest for your project.
General principle:
Configure Apache on your development server so that it picks up your checked out working copies as separate subdomains. Using this, you can simply make a checkout of your project and it will automagically be up and running. No need to touch the Apache configuration. You need a DNS wildcard entry so that all subdomains of dev.example.org go to your development server.
The only problem with using the above Apache configuration locally is the DNS wildcard. Unless your desktop is assigned a hostname by your network's DNS server and you can set the wildcard there, you will have to make do with your localhost address. You can install dnsmasq to act as a local caching DNS server and put the wildcard on your own machine
Use dnsmasq so you can achieve the same effect on your own development machine. That way you can develop your web applications locally and you won't need a central development server. In my examples I will be assuming you use subversion for your version control, but it works virtually the same with other version control packages, such as git or bazaar.
Note: (Humor)
This other question on Subversion allowed me to point out to this article about publishing its (source-controlled) data into production, with in it probably the ugliest diagram I ever saw on the topic ;-)
If I had not bumped into git, I would've doubtless gone with SVN. Having said that, I would recommend git.
Nowadays, I would certainly go with a distributed version control system. Setup is faster since you don't need to set up a version control server and everything, all you usually need to do is initialize a certain directory within your development box for version control and you're good to go. They also seem like the way to go these days. If it were 2001, I would recommend a centralized system like Subversion. But it's 2008, everyone is moving to distributed systems and user interfaces and supporting tools tend to get better.
Here are some suggestions for you:
Darcs: Easy to learn and has all the features you will usually need
Mercurial
Git: Powerful. May take some time to understand but evolves rapidly
All three of them should be readily available in your Linux-based OS through the usual package management solutions.
SVN is great.
Nowadays the hype around DVCS.
I prefer Bazaar.
Because of it's name, the support, the feature set, and it works well on my window$ machine too.
I'm using unfuddle.com and I love it. It's free for a one person web app
The answer really depends on your way of thinking. I personally had problems switching to subversion from SourceSafe. If you come from microsoft shop, I'd suggest using SourceGear Vault, it is free for <=2 users. If you come from non microsoft area, then using subversion would be preferrable. Also please consider git if working on linux.
HTH, Valve.
Personally I use monotone, learning a DVCS is definitely the way forward.
For a one-man job, pretty much any revision control system will do the job. It's when you get into multiple people, and past that into multiple repositories, where there start to be differences.
Given that, I'd go with whatever Free Software system your development environment supports best. I see Subversion and Git mentioned and both are fine choices.
SVN would been my first choice. If I have to take a second choice I would go to CVS.
One of the most popular models out there today is Subversion. It's generally easy to setup & configure and is able to handle multiple platforms.
SVN. If one does not need concurrent access (which is your case), it is VERY easy to setup as no server is required at all. Definitely your weapon of choice.
I wholeheartedly agree with SVN. Command-line SVN is quite easy too.
While I like svn a lot, I've found mercurial handy for having the whole repository locally. (the same goes for git, but its interface is a little less polished in my opinion.)
I'm not able to answer the question as asked, because I don't develop on a Linux server.
But maybe this experience has a counterpart in Linux world.
I use a local-on-my-LAN-only IIS server (actually on an old laptop that no longer travels but works as a little server). I have VSS installed on that server too. There is an integration between the IIS Server, the FrontPage extensions on that server, and the VSS.
The upshot is that I can use FrontPage to build and edit my site and build a development image that is always backed up in VSS, and I can check out, check in, and do all of that from within FrontPage.
Now, the way I publish is I take advantage of the sharing capability of VSS so I have a deployment image that shares with the project that is actually an IIS web site. I have a deployment-image directory that I can transfer the latest checked-in material to (material that has not changed is not updated). I then deploy the deployment image to the hosted, public web site using FTP (again, only transfering new and updated files).
I present all of these details to suggest what might be the use-case of interest, even though a different solution approach is needed with Linux.
If I wasn't using a tool that integrated with the web server and also the source control at the server, I could do something similar by checking the VSS material in and out of a local directory and then pushing the updated VSS project to the IIS server web-pages directory hierarchy. The workflow is a little more clumsy. In this case, I would not edit pages directly on the development web server unless I could lock check-in pages as read-only or something.
Does this suggest anything that might be appealing in the Linux server case?
Definitively Mercurial is a good choice, quick, easy to use, perfect for working alone, or with multiple other developer, perfectly multiplateform, handles merges, branches, etc. very simply, plugin based, there are great tools out there such as nice IDE plugins (notably Netbeans and Eclipse).
Robust, it works just as you a expect such a tool to work, not like SVN (and I have years of day to day)...
Both Sun, Xen and Mozilla host all their repos on Mercurial. We're currently moving from SVN to Mercurial after a 6 month daily test, without any regret.
I once used Perforce and was impressed with it. There's GUI and command line versions and it supports Windows, Linux, Mac and Unix for both the server and client. It integrates with Eclipse and has APIs for writing your own client applications (C/C++, Ruby, Perl, Python) It only supports two users and five workspaces before you need to buy licenses though (but that is within the scope of this question).
Subversion is a good choice. For the client, there's TortoiseSVN (http://tortoisesvn.tigris.org/) that integrates with the shell and lets you do things with a right click on a folder. For integration with Visual Studio (I'll assume that's your environment) there's VisualSVN (http://www.visualsvn.com/) and AnhkSVN (http://ankhsvn.open.collab.net/). For the server there's a one-click installer you can find here (http://svn1clicksetup.tigris.org/) that does the setup in a snap. VisualSVN also has a (free) server that you can use which provides it's own web access and security (rather than using apache) and has a mmc-snapin for managing/creating repositories and users.
CVS - No, I'm not joking. Not that it is better (it is not) or the simplest (it isn't), but it really doesn't matter at the end of the day. The important thing is to get started with ANY version control system even if it is a one-developer shop, even if it is CVS.
Related
I'm looking for a version control system just for me on my windows computer to integrate into eclipse. I was thinking to use Mercurial instead of Subversion, but I'm having doubts about the mercurial eclipse plugin. Any input on this that you can help me with?
Is it worth it to have a version control system when you're working alone, how much is it going to complicate matters? I don't think I need a remote repository since it's just for me. And what is known to work well in eclipse?
Is it worth having a version control system for just yourself ? Absolutely. Why ?
You can retrieve old versions of code - for reference, to revert changes.
you can branch and tag to create different versions and checkpoint for releases.
Your continuous integration system (you do have one, don't you?) can tag successful builds, allowing you to identify particular intermediate builds.
You can record in the logs why you've changed stuff (as opposed to what you've changed), and meta-information surrounding those changes.
So version control isn't used to manage multiple developers, but rather to manage the codebase itself.
What works well in Eclipse ? I can vouch for Subversion. I've used that successfully for a couple of years. I'm not sure I'd use a distributed system like Mercurial, unless I was in the habit of (say) developing on a laptop on the move, and on a desktop at home.
I have used the Subclipse plugin for SVN and it worked like a charm. In regards to whether or not you need a version control system while working alone, it's still a good idea. It will save your version history and allow for easy rollbacks. Also, if you ever bring on another person to the project it will be easy to get them up and going.
Is it worth it to have a version control system when you're working alone
Yes of course, you will always run in cases like, the application was running yesterday but i dont know what i did!
how much is it going to complicate matters?
It will not complicate anything, you will just need to spend half an hour at the beginning to set it, then committing,branching, uploading, sharing will all be one click away in Eclipse.
I don't think I need a remote repository since it's just for me.
I work alone as well, but you never know, if you might work on different sites it would be good to have all your work in the cloud, sometimes you run in cases like you want to share a project with a friend and whats better than SVN in that case.
And what is known to work well in eclipse?
I use Subversion, inside Eclipse and TortoiseSVN in the explorer.
If you want to setup your own SVN Server, (with the benefit of not needing to upload/download from internet each time) check here:
Create SVN Server on Windows
Create SVN Server on Mac
It IS important to have a SCM system even when working alone.
I'd suggest creating a project in code.google.com or sf.net, (unless of course you don't want an open source license).
Eclipse has built-in "Local history", you can check if it is sufficient for your needs. Otherwise you can simply install an SVN server from Collab.net, and use it on localhost with Subclipse
There is also a git plugin for eclipse. only problem is merge not being integrated yet. but is planned for the near future.
egit
The Mercurial plugin for Eclipse seems to work fine. I don't think it has all of the features that Subclipse has for Subversion though.
If you are working alone on a project though, you need to ask yourself why you are using a distributed version control system. For a project by yourself, Subversion works great. I use subversion and the eclipse project for projects I work on by myself. It gives you the history and rollback capabilities even with a single person. It is nice sometimes to be able to see what you did before that you might have deleted.
In a team environment though, the Mercurial plugin for Eclipse works fine.
I'm just getting into the practice of version control (I'd like to use Eclipse and SVN), and I'm not sure the best setup for my scenario.
I'm currently a lone developer and I have two computers (a work desktop and a home office laptop) that I like to use for development (mainly web-based stuff). I have access to a Linux-based and a Windows-based remote server, and I seem to always have files scattered between the two machines based on where I conduct the work.
Are there any instructions or best practices about how to set up a development environment so that when I sit down at either machine I have the same files to work with and the ability to utilize version control?
Some things I have used between my laptop/workstation/server.
If the paths are exposed create a local svn repository, and then use the network path to the repo from the second machine. Works well if you dont want to run a server but just use local files. My laptop and workstation have the same credentials, so pass through works great with the hidden paths '\machine\c$\etc'
I also like to use Unison for managing the files between my laptop and workstation. Its not versioning, and with date time hints it does rather well at 'which is newer'. Also, if you're the only one using both, conflicts are really low. I use this to manage my 'my documents' http://www.cis.upenn.edu/~bcpierce/unison/
Of course you can create an SVN server, and I have found Visual SVN to make this almost too easy. I started using this for my personal projects after the need to 'launch' to the server came up. Having the svn server on the remote server had a few benefits when it came to launching and working from home. (Or inviting other developers) http://visualsvn.com/server/
Just install SVN on one of your computers (preferably on the Linux server). I guess administrators will install SVN for you and create needed repositories.
Integration of SVN with Eclipse is really easy through plugin.
If you are new to source control (or even if you are not), reading Eric Sink's Source Code HOWTO will give a good introduction and expose you to some best practices.
I would consider a distributed version control system as well as Subversion. Even if you do go with Subversion in the end, it's good to understand all the options available to you. Personally, I'm a single developer and work in multiple locations, and have found the DVCS concept to work much better than SVN.
Git, Mercurial and Bazaar are three options. Here's a good video by Linux Torvalds which explains some of the conceptual differences.
I am implementing Bazaar as my source control solution for handling this scenario. I have used Subversion for years, but it simply does not really fit this distributed usage scenario. Bazaar does.
I'm about to start a project where programmers will be contributing from their homes (much like stackoverflow was built)
I want to use some centralized source control, but I don't want it to require the programmers to be online, and the server may come offline from time to time (as at first it'll probably be my desktop machine)
I think I remember Jeff talking about this in some podcast, but I don't remember which one.
Is there a source control tool that works perhaps asynchronically by e-mail?
Programmers could connect to download the latest version, and the checkin process would be sending files to an email account for example
Does such a thing exist?
EDIT: Sorry, I forgot to say that I'll be working with .NET (Visual Studio 2008)
It'd be great if it could be integrated into this environment... does GIT (suggested below) support that?
git is basically built with this scenario as one of the major requirements.
Others support it as well, they usually go under the name of "distributed version control system".
You're looking for a Distributed Revision Control, system such as Git, Bazaar, or Mercurial.
I personally like Bazaar because it has good windows support.
I think Mercurial may be the best choice in your case, as it seems to have a Visual studio plugin. It does have a web interface and ssh support, which are probably better options than email, but there is also an extension that allows patches via email.
You could use git for this purpose. It doesn't require access to a centralized server, but you can set one up if you want to. Git differentiates between commit and push/pull, so working offline works great. The git website has great documentation.
git and mercurial will both do this; they allow syncing via emailed patches. Other distributed source control software will probably also work.
Subversion is what Jeff was talking about in the podcast. You can buy VisualSVN for Visual Studio integration. svn works very well offline as you don't need to talk to the server unless you are checking stuff in, or getting stuff out.
Sourcegear vault has an add on that allows this
There's also a free SmartSVN tool for Subversion, which integrates with Windows shell (adding fancy icons that let you distinguish locally modified files from pristine etc).
I've used Subversion and SmartSVN when working from home as well as in the office, and I can only recommend it. Check its features here.
What's the recommended source control system for a very small team (one developer)?
Price does not matter. Customer would pay :-)
I'm working on Vista32 with VS 2008 in C++ and later in C# and with WPF. Setting up an extra (physical) server for this seems overkill to me. Any opinions?
I would use Subversion (in fact I use it) [update: Jul 2014 -- I use Git -- see end of the answer].
SVN is:
free,
good enough (see disadvantages below),
simple,
works fine on Windows (and Linux too),
a lot of people use it so it's easy to get help,
can integrate with most of IDEs i.e. Visual Studio (i.e. ankhsvn or VisualSVN -- more info) or Eclipse (i.e. Subclipse -- here someone asked about that).
I would strongly recommended separate machine to source control server. At best somewhere on the cloud. Advantages:
You don't lost your source control repositories if your development box dies.
You don't have to worry about maintenance of one more box.
There are companies which host SVN repositories.
Here are links to SVN (client and server) packages for various operating systems.
Disadvantages of SVN
I am using SVN on Windows machine for about 5 years and found that SVN has a few disadvantages :).
It is slow on large repositories
SVN (or its client -- TortoiseSVN) has one big disadvantage -- it terrible slow (while updating or committing) on large (thousands of files) repositories unless you have SSD drive.
Merging can be difficult
Many people complain about how hard merging is with SVN.
I do merging for about 4 years (including about 2 years in CVS -- that was terrible, but doable) and about 2 years with SVN.
And personally I don't find it hard -- on the other hand -- any merge is easy after merging branches in CVS :).
I do merge of large repository (two repositories in fact) once a week and rarely I have conflicts which are hard to solve (most of conflicts are solved automatically with diff software which I use).
However in case of project of a few developers merging should not be problem at all if you keep a few simple rules:
merge changes often,
avoid active development in various branches simultaneously.
Added in July 2011
Many devs recommended Distributed Version Control like Git or Mercurial.
From single developer perspective there are only a few important advantages of DVCS over SVN:
DVCS can be faster.
You can commit to local repository without access to central one.
DVCS is hot thing and fancy to use/learn (if someone pay for your learning).
And I don't think merging is a problem in case of single developer.
Joel Spolsky wrote tutorial about Mercurial which is definitively worth to read.
So, despite of many advantages of DVCS I would stay with SVN if merging or speed is not a problem.
Or try Mercurial, which according to this and this SO questions, is better supported (in July 2011) on Windows.
Added in July 2014
For about a year I use Git (Git Bash mainly) for my pet-projects (i.e. solving Euler problems) and local branches for each Euler problem are really nice feature -- exactly as it is described as advantage of DVCS.
Today Git tooling on Windows is much, much better then 2 or more years ago.
You can use remote repo (like GitHub or ProjectLocker and many others) to keep
copy of your project away from your workstation with no extra effort/money.
However I use GUI client only to looks at diffs (and sometimes to choose files to commit),
so it's better to not afraid of command line -- it's really nice.
So as of today I would go with Git.
I would also recommend Mercurial. It's command set is much like the one found in Subversion, so the learning curve is not that steep. As mentioned earlier, it's designed to run locally, but it's also easy to share/merge changes across computers, or even just push it to a remote server for backups.
It offers excellent tools, like TortoiseHG, and it has good plugins for NetBeans and Eclipse. It also runs natively on Win32, as it's written in Python.
If you don't want to set up a server yourself (for backups, e.g.), there are free hosting providers available; there's a comprehensive list on The Mercurial Wiki.
I would definitely recommend git
Works great for both big and small teams. Only drawback is poor native windows support. Although it works fine for me in Cygwin. There also exists a native windows port.
Some of its benefits:
Excellent support for a non-linear work flow. Its branching and merging is far better than eg Subversion.
Good tools to navigate your repository
Handles large projects well.
It is not possible to modify the history without changing the cryptographic signature of your repository
With its non monolithic design, it is easy to script.
Some people find that it has a steep learning curve. But once you understand it you can do almost anything you would want with it.
Go for subversion and tortoiseSVN, you don't need to set it up on a server.
Costs are zero
The subversion documentation is great and fun to read
tortoiseSVN is a very convenient client
Subversion has very low barrier to entry.
TortoiseSVN is a free client, and integrates into your explorer- i.e. in right mouse click menu.
The repository can be just a directory somewhere on your PC or on a network drive. Backing up just means zipping up this directory
There are a few plugins to Visual studio for Subversion, AnkSvn is one I have used, it is free and integrates nicely (i.e it will be smart about moving and deleting files etc)
Subversion is a good choice for one developer.
Update:
Since this post, I've been using Mercurial. It is a Distributed SVN. The 'distributed' aspect may not be directly useful to a sole developer, however it is better at merging and is somewhat faster. There is also a free and good Windows Explorer extension client - Tortoise Hg.
So in summary, if you are the sort of person who will work on many branches at once (doing spikes etc) or if you work on multiple PCs at once and would like full offline access to checkin history on both, then Mercurial. If you just want simple tracking and a well proven and easy to understand solution, then Subversion.
Sourcegear's Vault is a great option, it runs on SqlServer and it has been around for many years. I would not use any version of VSS (Visual Source Safe).
I'm surprised no one has mentioned Perforce. It's free for 2 people, blazingly fast, and integrates with VS. Also source server has bindings for it by default.
In addition to source control, it really is worthwhile to complete the loop and setup a symbol server and a source server, so that you have simple debugging of anything you've shipped (e.g. no more searching for pdbs or source that match the binary). Both source and symbol server are completely free and supported in VS since 2005.
You can use Vault from SourceGear, the replacement tool for visual studio source safe.
The IDE is integrated in Visual Studio.
The tool is free for single user.
More information: http://www.sourcegear.com/vault/index.html
I use Mercurial. It runs a treat running stand alone on my Vista development system with no other dependencies required. I use the command line but there's also TortoiseHG to integrate with Explorer.
Two comments:
There are other tools which probably integrate with VS better. I think Subversion has nice VS plug ins.
The benefit of a separate server is that it's a nice backup of all your work in case your HDD dies on you etc. so discount having one.
Edit: #Slartibartfast - if you just want to run source code control on a single machine a Distributed Source Code Control tool like git or Mercurial is ideal since they're designed to run complete repositories on a machine without the overhead of a server. The fact that you never connect your repository to anyone else's to push and pull changes doesn't mean that tool won't be right.
There are two possible solutions for your problem: centralized VCS or Distributed VCS (DVCS).
Centralized VCS like Subversion would satisfy you feature for committing and browsing the log. It also enables you to safely store your repository to another computer which should be one of your major goals as hard drive failure is always a possibility. However, using Subversion the history still resides only at the central location making it vulnerable and you stated that you do not want to have another server.
Distributed Version Control Systems (DVCS) such as Mercurial and Git enable you to do more complex operations on your repository. With both of those tools the whole repository resides with the same computer making it bit easier to make backups and using the repository with another computer e.g. laptop. While Mercurial might seem complex at first the operations you would use with subversion are pretty much the same with Mercurial. Therefore there is no extra overhead to get started if you already know Subversion and you can easily use more advanced features of Mercurial later.
You should be able to find online repository service for your Mercurial repository enabling you to make easy backups and do collaboration some day if you have the need for it.
My recommendation is Mercurial with TortoiseHg.
A source control system doesn't care if there's only one developer involved :)
I would recommend that you use a source control system that you've used before and liked.
If you like vs 2008 integration of the source control system however I would go with TFS although I never had the experience to set it up but it shouldn't be so hard.
Another possibility is to use svn (you'll find some servers on google) and use Tortoisesvn that integrates into the windows shell and is nice to work with.
A number of the posts advocate putting the repository on a server because it provides redundancy. I don't think this is all that helpful for a single user. Using a separate server machine adds a lot of complexity, but it doesn't buy much redundancy: if you lose the server machine, you still have the current sources on your development machine, but you may have lost ALL your history. Putting the repository on a server does make sense if that server is being regularly backed up. Using an exernal hosting service for the repository can provide storage redundancy, but you're at the mercy of the external service AND you need an internet connection to access the repository. If you use an external host, make frequent backups of the repository that you keep control of!
I would presonally recommend TortoiseSVN using a local file based repository. Just make sure you backup the local repository to a second machine or external media (such as CD-ROMs) on a regular basis.
I'd recommend two things:
First up, that other server - what happens if your machine dies? the house burns down? etc. Having it on another machine is a good idea from a redundancy point of view.
The second one is WHAT:
If you are very familiar with visual source(un)safe, think about SourceGearVault. It's VERY nice, very fast, and very much a vastly improved "clone" of VSS (ie works the same way from the users POV, not under the hood). Needs SQL server and windows tho (it's .NET + SQL server). Free for 1 user.
Of you are not, then I suggest you do one of two things:
First, get VisualSVN. It's great, works with VS2008 really well.
Second, if you MUST run it locally, get VisualSVN server (free!). Make sure you have a good backup plan. Runs on XP/2003/2008/Vista etc.It's just Apache + SVN, under the hood, so it just saves you on the setup - took me 5 mins to install and have it running.
OR, and I prefer this one:
go somewhere like Unfuddle, Dreamhost etc, and get hosting for SVN. It's private, it's fast, and most of all - it's OFFSITE. My dreamhsot account, with something crazy like 500GB of storage and 1-2TB of transfer/month costs about $6/month! There are others which do SVN hosting + bug tracking etc. Look around.
But yeah - SVN is the schizzzznit.you could create a local repository, but I like having a remote, backed up server.
TFS is total, utter overkill for 1 developer (or <5 IMO)
I realize that cost isn't a problem but a nice free solution that wouldn't involve checking in and out would be to host the code within Dropbox by doing this you'd instantly get versioning and backup which are the main features that a single developer system would provide.
Bazaar is a good version control system. I like to use it for my linux configs because you don't need to create a separate repo.
A while back I did a how-to blog post on using SVN with only one developer.
I called it Single serving source control
Well, for start, you don't need distributed one :)
I'm not sure what this physical part means, because you could put svn server on your own machine in little trouble.
On the other hand, NetBeans have local history module that logs all local changes of a file. Maybe something like that would be enough for you if Visual Studio have something similar.
I would recommend Subversion since it's for single developer and I assume that you're not doing complex merging and lots of log/history checking.
Seems like many people are using http://svnrepository.com/ for their hosting. It comes with Trac and even Git if you need it later.
Some good answers here.
I want to re-iterate the suggestion to use a separate computer to host the source control server, although it doesn't have to be a dedicated machine. It could be your Windows Home Server box, or some other server you're already running. Or it could be a virtual machine hosted on some other server. Whatever, just make it separate from the machine(s) where you write code.
I also want to suggest that you get a good backup discipline for your server. Something nightly at least; hourly if you can. Back up to a dedicated device (like an external hard drive) or something offsite (a server in your cousin's house in another state) or in the cloud (Amazon S3). Remember that your source code is your key asset; take care of it!
I've been working with Bazaar now for a few weeks and really like it. I'm a linux developer so don't really know much about Tortois but if you like it you should know that there is a Tortoisbzr
Hands down I would use git, and I believe many reasons why a single-developer would like to use git are hinted at or described in git magic
I use Springloops - version control tool for developers
SVN / Git version control
Automatic deployment to servers
Create repositories
Invite people
Import files
Great support
So, try Springloops
I dont see why the fact that your one developer changes anything on the source control issue. I would follow the same system (in fact I do on my solo projects). I use wush.net (svn and trac) in those cases. It's fast to set up and dont require that you yourself do or know any server issues. I recommend you use something like this.
I would recommend using subversion. Many have recommended using a seperate box as a server, in case your dev machine dies. What happens when the SVN server dies? The answer here is that no matter where you choose to run the server, ensure you always do frequent backups, possibly automated daily to some secondary, preferrebly offsite machine.
I use Perforce as well for my own personal stuff, mainly because we use it at work. There are emacs bindings for it as well, so you can sync, check stuff in or out, etc. all from within emacs.
I recently moved my studio from Subversion to Perforce and put some notes about it, sort of a postmortem, on my blog here. Hope it's useful.
I am looking for a lightweight source control system for use on "hobby" projects with only one person (myself) working on the project. Does anyone have any suggestions? Ideally it should interface with Visual Studio either naively or through another plug-in, outside of that, anything that works would be nice to be replace Gmail as source control.
I use VisualSVN Server (free) and Tortoise SVN (free) for school, work, hobbies, everything. If you want Visual Studio integration, you can use Visual SVN ($49) or AnkhSVN (free).
You can use assembla.com to host your project. They offer subversion, git and mercurial hosting. I personally use their subversion hosting for a free and private one-man project. As an added bonus, you also get a wiki and a ticketing system. Which can help you manage your stuff.
And the best thing is that you don't have to setup your subversion server and it is hosted off-site.
It's really good for a free service.
Personnaly, i use TortoiseSVN as my client but it isn't integrated in visual studio.
For the integration, you can try VisualSVN (not free) or AnkhSVN (free)
Have a look at the Mercurial Project an open source distributed source control system. There is a tortise and an eclipse plugin but nothing for visual studio plugin that I know of.
you can see a demo on you tube . like GIT its one of a new breed of distributed source control systems, so no server setup required, and it has very fast HTTP based checkin's with advanced branching and merging facilities.
Git is very lightweight and is just as suitable for personal projects as it is for huge projects like the Linux kernel. There is lots of tutorial documentation available on its web site that will get you started. Example:
git init
git add .
git commit -m "my first commit!"
If you are keen on Visual Studio integration, I would probably recommend Subversion, as there are a number of plugins that may make your life easier. Also, TortoiseSVN is definitely worth installing.
Hobby or Serious project, SVN 1-Click Setup (download Svn1ClickSetup-1.3.3.exe) gives you all you need with ease :)
TortoiseSVN works great. You don't even need a Subversion server, you can create a local repository through the tool. Since it integrates right into Windows Explorer, it makes it easy to work with in a variety of scenarios. You also then have the option to work with remote Subversion servers or Team Foundation Servers (via SVNBridge).
I prefer distributed version control for personal projects, because they eliminate the need for a server. Mercurial is the one I try to use most of the time, but I've been hearing good things about git as well.
I can't comment on other source control software but after using VSS 6.0 , StarTeam, Vault and SVN I cannot rate SVN + Tortoise more highly. AnkhSVN is a free plug-in for Visual studio which I personally didn't warm to. Apparently Visual SVN is much better but costs money.
SVN with SmartSVN or tortoiseSVN ? not really all that lightweight, but good practice for the big bad world.
Pick your flavour of distributed version control. I like Mercurial, other folks swear by Git and Bazaar. There's no need to make a fake server to put a directory under version control, which, IMO, makes it very ideal for small projects.
I'm not sure if any of these have Visual Studio plugins, though.
If you have access to SQL Server, then SourceGear's Vault is free for a single user. If you want to go even further, Axosoft's OnTime issue tracking is also free for single user use. I use both at home (for free) and we also use both (licensed) at our company. Both integrate into Visual Studio, and OnTime also supports Vault integration.
I use Perforce at work and at home for hobby projects. It is easy enough to set up, and allows two users and five workspaces without having to pay for a license. Also has a Visual Studio integration plugin.
Lately I became a strong believer in Git and its interesting index pseudo repository. But if you do not need all the fancy rebase --interactive and stuff like content over file tracking - and as its Windows support is a weak point - Hg is a valid alternative. I am rather certain neither has a VS plug-in but with PoSH the command line is more fun anyway.
Thanks for all of the help so far, I have things up and running and right now I am working with Assembla as a Subversion server, TortoiseSVN for general Subversion access, and AnkhSVN for Visual Studio integration. Overall I am quite impressed with this particular configuration and I am already much more impressed with it than I have ever been with Visual Source Safe.
I have had a couple issues getting things up and running so I think it is best if I mention them in case anyone else ever runs into these problems -
AnkhSVN doesn't give any useful error messages if it can not connect to the server due to a proxy being in the way and it doesn't use any of the Internet Explorer proxy settings so you have to configure it yourself. At the time of this post (2008-08-20) that information is in C:\Documents and Settings[USERNAME]\Application Data\Subversion\servers
Assembla runs over HTTPS but shows the SVN URL as HTTP, you must be sure to change the HTTP to HTTPS yourself in the URLs or you get a "401 Not Implemented" error from TortoiseSVN and AnkhSVN.
For small and not-so-important project, Google Code Hosting is wonderful - it's Subversion, it's free and offers plenty of space.
I prefer Mercurial for my homebrewn projects. It's much easier than Git, and it works flawlessly under Windows.
i will never use SVN again for a personal project - ya its great compared to CVS, but isn't even in the same class as the modern breed of distributed version control systems. GIT has been mentioned already but a) it has shaky windows support b) complicated learning curve. I now use BZR which "just works".
bzr vs git
bzr in 5 minutes