

Ask HN: How do I get started with version control? - quizbiz

I do mostly wordpress dev and design. Most php, css, xhtml, jquery but I am looking to advance and work on some web apps in the near future.<p>I have grown to appreciate version control and I know most people here think very highly of Github. However, I have no idea how to even get started with taking advantage of github or any form of version control. I would appreciate your input. FYI: I do my work with Coda on a Mac.
======
gcv
I myself prefer Git, but Joel Spolsky wrote a really slick tutorial for
Mercurial: <http://hginit.com/>

Once you learn about how VCS works, and have used something for a while,
you'll be able to make an educated decision about switching to something else.

~~~
arien
The Subversion re-education bit is great to understand the differences between
Mercurial and SVN, thanks for the link :)

------
chasingsparks
Github has some good resources.

<http://help.github.com/>

If you want to understand how git works -- and therefore know what it can do
-- see: <http://ftp.newartisans.com/pub/git.from.bottom.up.pdf>

------
eswat
If you go ahead with trying out git, then check out Pro Git:
<http://progit.org/book/>

Read the first 2 chapters, sign up for an account on GitHub and mess around
with a public repo for a bit. Once you become familiar with adding, staging,
commiting, etc. then you can either try out another VCS like Mercurial or SVN,
or move onto Chapter 3 and get comfortable with branching and merging in Git.

There's also a very nice GUI for Git on OSX called GitX. It won't let you do
push/pull on remotes but it's great to understanding what's happening to your
repos outside of a CLI: <http://gitx.frim.nl/>

~~~
admp
There's also an experimental fork of GitX that adds basic support for
pulling/pushing, etc. See here: <http://github.com/brotherbard/gitx>

~~~
weaksauce
I know it's experimental but how stable is it in practice?

~~~
admp
Have been using it for over a month now, no problems yet.

------
taphangum
There ya go mate: [http://net.tutsplus.com/tutorials/other/getting-the-hang-
of-...](http://net.tutsplus.com/tutorials/other/getting-the-hang-of-github/).

Then try this: [http://net.tutsplus.com/tutorials/tools-and-tips/terminal-
gi...](http://net.tutsplus.com/tutorials/tools-and-tips/terminal-git-and-
github-for-the-rest-of-us-screencast/).

------
bwh2
Subversion would also work just fine. Some hosts already have Subversion
installed, so setting things up is quite easy. Here are some examples:

Dreamhost: <http://wiki.dreamhost.com/Subversion>

MediaTemple: <http://kb.mediatemple.net/questions/143/Using+Subversion>

I use Subversion for projects that I don't release open source. For me, that
works better than paying github a monthly fee. Anyway, the point is that you
shouldn't feel like git is the only option.

~~~
prog
I have been using bzr for quite some time. While my host didn't provide bzr
(but did support Python), it was just a matter of untaring it and adding it to
the path on the server. It worked out quite well as one fine day the server
crashed and lost all the data. Luckily I had a bzr repo locally so it was just
a matter of pushing it to the server.

For private hosting I basically use bzr+ssh smart server on my host and
launchpad for my hobby projects.

------
pingswept
It seems you're getting a lot of advice to choose Git or Mercurial over
Subversion. I haven't used Mercurial, but I have used Git and Subversion for
years.

I think Git (or maybe Mercurial) is actually the answer to a different
question: "What's the best version control system to use?" Starting with Git,
particularly if you're not using OS X, which has better GUI tools for Git,
seems to me to be a quick trip to insanity. To get started with version
control, I think Subversion is substantially easier.

But it's not too hard to try both. Make an account on Github, create a
repository, and try it out. If, by tomorrow night, you want to gouge your eyes
out with a spoon, try Subversion.

(Subversion will definitely make you want to gouge your eyes out too, but not
for a few months. Then you can switch to Git!)

~~~
philwelch
Git would actually be easier, I think, for most people to learn if they didn't
already have Subversion experience and hence Subversion ways of doing things
coloring their preconceptions. It's a beast of a system though--you have to
actually learn how to use it, rather than depend on your intuition and hope
that it's usable--but it's worth learning and probably easier than learning 1
or 2 other version control systems and having to unlearn them along the way.

~~~
pingswept
As someone who has been slowly unlearning SVN, I agree. Still, learning
Subversion was trivial compared to Git, regardless of which I learned first.

------
jonpaul
My vote goes to Git. The way you get started is to just do it. Everyone has
there preference, but I highly recommend any DVCS.

<http://whygitisbetterthanx.com/>

------
user0
I would suggest trying out bzr as its easy to use and has good integration
with launchpad.

The 5-minute tutorial[1] is a good start. You can also look at the quick
reference[2], its quite self explanatory.

[1] [http://doc.bazaar.canonical.com/bzr.2.1/en/mini-
tutorial/ind...](http://doc.bazaar.canonical.com/bzr.2.1/en/mini-
tutorial/index.html)

[2] [http://doc.bazaar.canonical.com/bzr.2.1/en/quick-
reference/i...](http://doc.bazaar.canonical.com/bzr.2.1/en/quick-
reference/index.html)

------
elbenshira
I really enjoy The Git Parable ([http://tom.preston-werner.com/2009/05/19/the-
git-parable.htm...](http://tom.preston-werner.com/2009/05/19/the-git-
parable.html)).

------
BoppreH
I'm facing a similar situation, but my coworker is suggesting SVN. Should I go
along or is there any good reason to start right away with git/mercurial?

~~~
Ixiaus
If your organization is using SVN stick to SVN because your learning curve
will be easier (rather than trying to learn two differen VCS systems).

Otherwise, I _highly_ suggest Mercurial; it "just works", has a powerful
feature set, and I like bitbucket.org better than github :)

The debate between bzr, hg (Mercurial), and git can become religious because
all the tools are good.

~~~
lenni
I use Mercurial for my personal one-person projects, too. It does its job well
and is very easy to use.

------
brazzy
There are a few reasons why you might want to start out with SVN rather than
git:

* It's simpler (though admittedly the complex and confusing features of git really only become relevant when there are multiple developers).

* If you're going to work for corporate clients with their own repositories, chances are very high it's going to be SVN (it's possible to use both via the git-svn tool, but that adds more complexity)

That being said, git does have a number of very nice features that are useful
to lone developers as well.

~~~
bradleyland
If you're eventually going to move to something like Git or Hg, you really
ought to skip SVN all together. The concepts you learn in SVN will make Git or
Hg seem counter intuitive, and the Git / Hg model is a better way to work once
you start using teams.

~~~
brazzy
My (second) point was that there's a good chance you won't be able to skip SVN
anyway.

------
ccarpenterg
Git is neat. This is the first time I use a VCS.

Git community book: <http://book.git-scm.com>

------
zppx
The best way to get started is using one, pick one and use it, generally when
I am learning a new tool I try to get the basics emulating my workflow, i.e. I
edit, create, move, rename and remove a couple of text files in the case of a
VCS, this also serves when I need to learn the commands and the concepts of a
new VCS (I'm a git user, but often I need to work with mercurial or
subversion).

------
nkm
Since Coda uses SVN, I would start by learning Subversion and then, when I
feel comfortable with it, make the jump to Git.

------
Osiris
I found a really easy way to setup a local version control.

1\. Install VisualSVN Server 2\. Install TortoiseSVN

Use VisualSVN Server to create a repository and set permissions and
TortoiseSVN to manage your files and commits.

For someone that hasn't use version control before, I think it's a really
simple solution.

~~~
arethuza
Why do you even need to install the server if it's a personal project - AFAIK
svn works just fine accessing repos on a local file system.

------
TrevorBurnham
I like the Git tutorial embedded within <http://railstutorial.org>. You learn
Git, complete with best practices, while developing a webapp with Rails.

After that, read Pro Git: <http://progit.org>

------
diegob
Project Locker is a good free svn/git provider with private repositories. It
also has trac for bug tracking, but I didn't use that much. The site isn't too
pretty but you can't beat free!

<http://www.projectlocker.com>

------
techiferous
The best resource is a person at your side. Pair-program a simple project
together and have them show you how to use github or git. If you're in the
Boston area I'll help you out.

