[LRUG] Learning ROR
Paul Lynch
paul at plsys.co.uk
Thu Nov 9 06:35:34 PST 2006
On 9 Nov 2006, at 12:34, Harjeet Taggar wrote:
> I just had a quick question regarding RoR and I thought this would be
> the best place to ask it. I've only recently starting teaching
> myself programming (I run a website and decided it was time to stop
> relying on other people to do all of the coding) and have started
> with PHP since that's what my site is built in. However I've been
> advised to stop learning PHP and go straight into RoR as I'll be
> building applications far quicker.
>
> I was wondering what people thought about this. In terms of my
> business, the site is PHP but I have enough developers at the moment
> so there is no urgent need for me to learn PHP in that respect.
> We've also been thinking seriously about converting over to RoR
> anyway and I though perhaps setting myself the goal of rewriting the
> site in Ruby could be a good way to learn and it'd be a cool
> challenge.
There are lots of reasons why Rails is a better tool to develop web
apps, and remarkably few reasons why it isn't. Or, to put it another
way, in your position I'd switch from PHP to Rails in an instant.
One of those reasons is that Rails is much easier for an
inexperienced programmer to create simple sites in than PHP.
> Finally - as someone who is pretty new to programming but tends to
> pick things up pretty quick, what is the best way to approach
> programming and are there specifically any particularly good ways to
> learn Ruby?
First point: Rails isn't the only web development tool for Ruby;
there are several others, although it is almost certainly the best
choice for developing CRUD style web apps. Second point: don't let
yourself get stuck on scaffolds, most developers will be producing
sites much more complex than a scaffold site, with very little extra
effort. Last quick point: it helps a lot if you have a decent grasp
of Ruby before approaching Rails, although it is by no means essential.
For an inexperienced programmer, you should look at Chris Pine's
Learning to Program book, which you can buy as paper or as a PDF.
See his site to start with, which gives an early version online:
http://pine.fm. There are several other beginning sources on the
web: Why's Poignant Guide (http://www.poignantguide.net/ruby/),
http://www.math.umd.edu/~dcarrera/ruby/0.3/, http://
www.humblelittlerubybook.com/, http://glasnost.itcarlow.ie/~barryp/
ruby-tut.html, and others. You might also want to take a look at
http://tryruby.hobix.com/, for an on-line Ruby sandbox with tutorial.
Once you get the basic idea, you need a copy of the pickaxe book.
This is Programming Ruby - there is an online version of the first
edition at http://www.ruby-doc.org/docs/ProgrammingRuby/, although
you really need the current edition.
That's for Ruby. For Rails, take a look at: Top 12 Ruby on
RailsTutorials (http://www.digitalmediaminute.com/article/1816/top-
ruby-on-rails-tutorials). Once you've seen the 15 minute
screencasts, move up to Four Days on Rails (http://
rails.homelinux.org/). You will need a copy of Agile Web Development
with Rails, second edition - which is in beta at the moment. Go to
http://www.pragmaticprogrammer.com/titles/rails/ for a pdf copy.
You will also want a copy of David Black's Ruby for Rails. There are
other books and resources, but these are the most important ones; I
assume that you already know the home sites for Ruby and for Rails,
and how to install them.
As to the best way to learn, there isn't a great difference from
learning anything else: study a little, and practice a lot. Look at
good examples, try making some programs, and communicate with others
doing the same.
Paul
More information about the Chat
mailing list