Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

Do you think it's worth it to use version control if you are an independent developer, and if so, why? Do you keep the repository on your own computer, or elsewhere, where it can serve as a backup?

share|improve this question
39  
I would love to see a pharmacist ask: "Should I store medications in an organized way or just throw them all in a drawer? Is it worth the effort?" –  Erik Dec 17 '10 at 0:48
    
@Erik Lol, good point. –  vedosity Dec 17 '10 at 0:51
16  
Just imagine working really hard for a week straight creating this awesome piece of software. Then delete it. How would you feel? It's not just storage. When something is broken that worked last week, you can look and see what changed and usually see what you broke. I still see 'professional' developers with backup001 and backup_backup001 folders mixed with their source. Form good habits while you are still young. –  Erik Dec 17 '10 at 0:58
    
@Erik Yuck, the backup folders sound nasty. I use source control for my projects, though I'm not really good at committing often. –  vedosity Dec 17 '10 at 1:15

8 Answers 8

up vote 48 down vote accepted

If you use decentralized source control (Mercurial or Git or Bazaar or whatever), you get advantages overs SVN/CVS that makes it easy, useful and powerful to use in cas you're indy :

  1. You commit locally : your project dir is your repo with FULL history. So you don't have to have a server, you commit directly in your repo, and you can have several repos in the same computer. Using a laptop that you open sometimes to continue working on your things? Great! You dont have to setup a server and if you need one later, it's easy and you just "push" and "pull" changes between repositories.
  2. It's made to ease experimentation : often you need to have an idea about a feature without polluting code. With SVN and CVS you can already use a branching system and ditch the branch if the feature is not as good as you wanted it to be. But if you want to merge the feature with the trunk version, you'll have a lot of hard to fix surprises. Git, Mercurial and Bazaar (at least) makes merges and branches really easy. You can even just duplicate a repo, work on it some time, still commit and kill it or push your changes in the main repo if you want.
  3. Flexibility of organisation : as pointed before, as you have repos that you organize as you need, it's easy to start alone and allow other peolpe to work with you by changing your organization. No organization is imposed so you just have to set it up and voilà. I often just push/pull changes between my own computers (laptop/desktop/server) and I'm still alone on my devs. I use Mercurial and that help me duplicate my work but also work on features I thought about outside on my laptop, then continue to work on other features on my desktop, then push my laptop changes on my desktop or server and merge the whole desktop+laptop and put it (as backup and future teamwork repo) on my server.
  4. It helps setting up backups: if you setup a central repo (on github if it's public, or in a private repo on bitbucket) you can easily write a script which will be executed each time a computer is boot, and then pass it to your friends so that it makes automatic backup of your work regularly. It's what I'm doing so now I'm sure it not be easy to lose my work.

In fact, currently, you have no excuse to not use a control source tool for any project. Because their more powerful and flexible than before and scale with your needs.

share|improve this answer
5  
There's always GitHub. –  HedgeMage Dec 17 '10 at 0:05
7  
Or bitbucket.org if you're using Mercurial. –  Terence Ponce Dec 17 '10 at 0:13
5  
Mercurial with a local filesystem repo on dropbox works really well for a single dev. –  Pieter Breed Dec 17 '10 at 8:29
1  
@Guillaume : A single developper can use the "distributed" aspect of a DVCS. I do. For example, I can work on computer A, push my work on my usb key, and then pull from this usb key on computer B. –  barjak Dec 17 '10 at 10:37
1  
@Guillaume "Distributed" is a technical aspect, not an organisational one. You can use a centralised constrol source system with an organisation with integrators only allowed to validate commited code. That's possible but hard to setup because of the centralised nature of the tool. But that's still an orthogonal problem. –  Klaim Dec 17 '10 at 17:45

Yes.

Even single developers need to sometimes see the state of their code from some past revision. And it's always a good idea to backup everything important, and that applies to all people.

share|improve this answer

Why not?

I'm a solo developer and I use BitBucket and Mercurial for my personal projects. Having the ability to revert and fork your code is just too good to pass up.

share|improve this answer
5  
+1 for BitBucket - they offer unlimited private repositories for free. –  Jon Sagara Dec 16 '10 at 23:41
    
The free private repositories are the reason why I use BitBucket over GitHub. –  Terence Ponce Dec 16 '10 at 23:43
    
+1 Mercurial ! Pretty much the same as Git but simpler –  Kami Dec 16 '10 at 23:53
2  
free private repo?? You might have converted me from git to hg. –  Gauthier Dec 17 '10 at 9:52
    
@Gauthier, yep, BitBucket has free private repos. I'm not sure if they're unlimited though. –  Terence Ponce Dec 18 '10 at 1:13

I find value in it, personally. My projects are all checked into git repositories (all of which I keep on multiple machines in case of a hardware failure). The most useful features are branching (so that I can run an experiment that messes with half of my codebase, and not worry about blowing anything up permanently) and reverting (which is basically just undo on steroids; in case I find that I made some mistake that is out of regular undo range).

share|improve this answer

Yes. It is very very useful. My friend Matt Gallagher posted this excellent article on this very subject just a few days ago to his "Cocoa With Love" iOS/MacOS development blog.

The article is Mac & Git centric but it covers the basics.

You may also be interested in the following StackExchange Questions (and their answers).

share|improve this answer

Worth?? Must! If you don't use Source Control then you don't control you sources, and that's bad. You can't diff you can't revert, you can't track changes - you'll spend hours trying to find out the dummy bug you just entered. It is better to have it on some backed up server, but you can also you your computer and use any backup method you find appropriate.

share|improve this answer
    
I actually do use source control, but I also tend to do things like over-engineering and adopting things that are overkill. I'm well known for this at work. Then again, I don't think any programmers where I work including me have worked anywhere else as a programmer, and most of us are still in high school. –  vedosity Dec 17 '10 at 0:50

source code control is utterly useless for independent developers, because as we all know:

  • independent developers never make mistakes
  • independent developers never go off on revisions that don't work out
  • independent developers never have more than one version so they have no use for branches
  • independent developers never care about what they changed yesterday or last week
  • independent developers never, ever need backups

Call me a "dependent developer": Mercurial repositories clone easily between my desktop, laptops, USB backup drives, and bitbucket.org. I've grown dependent, and I like it that way!

share|improve this answer
    
+1: Exactly. The only extra thing a team adds to the reasons is to share code. –  Richard Dec 17 '10 at 7:40
3  
Is this answer sarcastic? –  user15279 Jun 27 '11 at 19:25
2  
@kurtnelle: extremely! –  Steven A. Lowe Jun 27 '11 at 21:20
1  
Kewlio, just checking. –  user15279 Jun 27 '11 at 23:28

Absolutely use source control. Then set up a build server and automate your build and testing processes. Trigger builds from your source commits of your central repo. I have been working by myself for three years in this way and it's wonderful.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.