David Black's book _Ruby for Rails

F

finetan

Hi all

Anyone of you have read the book, David Black's book _Ruby for Rails?

I 'd like to know what you think about the book from a professional
perspective.

Your insight some might find it useful.

-Jimmy
 
E

Emilio Tagua

Hi all

Anyone of you have read the book, David Black's book _Ruby for Rails?

I 'd like to know what you think about the book from a professional
perspective.

Your insight some might find it useful.

I think it's a great book, i would highly recommend it *after* reading
and understanding "Agile Development with Ruby on Rails".

It gives you an idea of what Rails does at the Ruby level. I wouldn't
recommend it as first book as i said before, maybe as a third
("Agile..." and a good Ruby book first). It has some great practices
and you will be a better Ruby programmer while doing apps in RoR.

Cheers
 
D

Daniel Waite

unknown said:
I 'd like to know what you think about the book from a professional
perspective.

Your insight some might find it useful.

I've read through the book, and, like those above, loved it.

What I got most from it was its *incredibly thorough* explanation of the
concept of 'self' in Ruby. Moments after finishing the chapter on self I
ran to _why's creature code and, line by line, explained exactly what it
was doing. I was so proud of myself. :)

One of the above reviewers cited the book as a Pickaxe killer, and I
would tend to agree. While I, too, start with the Pickaxe, I could never
get passed the first hundred pages or so. I primarily used it as a
reference. R4R though was a smooth read through and through. Mr. Black's
knowledge of how Ruby works is top-notch, and an awesome, awesome gift
for anyone serious about developing in Ruby.
 
J

James Edward Gray II

I've read through the book, and, like those above, loved it.

What I got most from it was its *incredibly thorough* explanation
of the concept of 'self' in Ruby.

That's a good point. I learned things from that explanation myself.

It is a very good book, though it will never kill the Pickaxe for me.

James Edward Gray II
 
M

M. Edward (Ed) Borasky

Emilio said:
I think it's a great book, i would highly recommend it *after* reading
and understanding "Agile Development with Ruby on Rails".

It gives you an idea of what Rails does at the Ruby level. I wouldn't
recommend it as first book as i said before, maybe as a third
("Agile..." and a good Ruby book first). It has some great practices
and you will be a better Ruby programmer while doing apps in RoR.

Cheers
Well ... I think you *can* learn both Ruby and Rails from _Ruby for
Rails_. Now "Agile" and "Pickaxe" are more or less mandatory as
*referenced* once you're developing Ruby or Rails code for a living. But
if you know nothing about either, I'd recommend starting with _Ruby for
Rails_.
 
R

Robert Klemme

What I got most from it was its *incredibly thorough* explanation of the
concept of 'self' in Ruby. Moments after finishing the chapter on self I
ran to _why's creature code and, line by line, explained exactly what it
was doing. I was so proud of myself. :)

You make it sound as if there was something complex about "self". Makes
me wonder whether I am missing something about "self". As far as I can
see "self" is an ordinary variable with these additional properties:

- it is automatically set to the current receiver and it cannot be
altered by Ruby code

- it is implicitly used for method invocations without an explicit
receiver and for instance variable access

Did I miss anything?

Kind regards

robert
 
D

dblack

Hi --

You make it sound as if there was something complex about "self". Makes me
wonder whether I am missing something about "self". As far as I can see
"self" is an ordinary variable with these additional properties:

- it is automatically set to the current receiver and it cannot be altered
by Ruby code

- it is implicitly used for method invocations without an explicit receiver
and for instance variable access

Did I miss anything?

Only the fact that in practice, grasping self is a stumbling-block for
a lot of people. In addition to just getting the concept of a
"default object", which is not always easy, there's the question of
where and when self changes, which can be confusing because it
sometimes overlaps with local scope but not always.

So I wanted to explain (and document and demonstrate) both self and
scope pretty thoroughly. Almost anything in the language can probably
be reduced to a couple of defining phrases, but just saying (for
example) that a class method is a singleton method of a class object
doesn't actually make everyone understand or feel confident about
applying the concepts involved. People really do learn in different
ways :)


David

--
Q. What is THE Ruby book for Rails developers?
A. RUBY FOR RAILS by David A. Black (http://www.manning.com/black)
(See what readers are saying! http://www.rubypal.com/r4rrevs.pdf)
Q. Where can I get Ruby/Rails on-site training, consulting, coaching?
A. Ruby Power and Light, LLC (http://www.rubypal.com)
 
J

James Edward Gray II

Almost anything in the language can probably
be reduced to a couple of defining phrases, but just saying (for
example) that a class method is a singleton method of a class object
doesn't actually make everyone understand or feel confident about
applying the concepts involved.

And David's description of the singleton class is another terrific
feature of the book.

James Edward Gray II
 
R

Robert Klemme

Hi --



Only the fact that in practice, grasping self is a stumbling-block for
a lot of people. In addition to just getting the concept of a
"default object", which is not always easy, there's the question of
where and when self changes, which can be confusing because it
sometimes overlaps with local scope but not always.

This reminds me of the headaches I had when confronted with OOP the
first time. That's quite a few years ago now and OOP has become my
second nature (or so) - that's probably the reason why I did not find
anything strange about "self". But true, for somebody relatively new to
OOP this might be considerably harder. I had forgotten that. But it's
good to be reminded of this once in a while.
So I wanted to explain (and document and demonstrate) both self and
scope pretty thoroughly. Almost anything in the language can probably
be reduced to a couple of defining phrases, but just saying (for
example) that a class method is a singleton method of a class object
doesn't actually make everyone understand or feel confident about
applying the concepts involved. People really do learn in different
ways :)

Sure. I didn't want to question the explanation (haven't even read the
book as I am not doing any Rails), I was just curious whether I missed
something. Thank you for your explanation!

Kind regards

robert
 
B

Bob Hutchison

Hi all

Anyone of you have read the book, David Black's book _Ruby for Rails?

I 'd like to know what you think about the book from a professional
perspective.

I'm pretty enthusiastic about the book. Ruby for Rails, in my
opinion, is targeted at someone who is using Rails already and is
feeling that it is time to learn Ruby. The book uses Rails as a guide
to explaining Ruby. This is really quite unusual for general
programming language books. You normally expect to see this when a PL
is explained as an embedded language (autolisp in autocad, mel in
Maya, come to mind). Trouble is that these books usually limit
themselves to what the author thinks is important in the context
(autocad, Maya). David didn't do that. He has managed to provide an
excellent how to program in Ruby guide within the context of Rails,
not just a how-to-use-ruby-while-working-with-rails book. I think
that it is better than that actually, David manages to use the
context of Rails to improve the presentation. This makes for a really
effective learning experience for people familiar with Rails, and
merely a really good experience for everyone else. It has the feel of
a well done tutorial.

On top of that, there are some really good explanations of
interesting aspects of Ruby in the book (e.g. the self/scope
discussion, Ruby-style domain specific languages).

It doesn't act as a Ruby reference, you'll need the Pickaxe for that.

Be aware: I'm quoted on the back of the book

Cheers,
Bob
Your insight some might find it useful.

-Jimmy

----
Bob Hutchison -- tumblelog at <http://
www.recursive.ca/so/>
Recursive Design Inc. -- weblog at <http://www.recursive.ca/
hutch>
-- works at <http://www.recursive.ca/>
 
L

Logan Capaldo

Well ... I think you *can* learn both Ruby and Rails from _Ruby for
Rails_. Now "Agile" and "Pickaxe" are more or less mandatory as
*referenced* once you're developing Ruby or Rails code for a living. But
if you know nothing about either, I'd recommend starting with _Ruby for
Rails_.
Seconded. I'd recommend Ruby for Rails even if you aren't necessarily
doing Rails. It's the best intro to ruby the language I've ever read.
 
F

fREW

And David's description of the singleton class is another terrific
feature of the book.

James Edward Gray II

I am now convinced. I am putting this on my to read list after I read
the Agile book (I have it and not the other and cannot order books
right now...)
 
J

John Joyce

I am now convinced. I am putting this on my to read list after I read
the Agile book (I have it and not the other and cannot order books
right now...)
It all really depends on what you want to learn. But I'd say that you
really should be comfortable with Ruby before doing too much with
Rails. Rails makes a lot more sense if you've really delved into Ruby
first.

The Pickaxe is a vital Reference book. buy it, keep it handy.

Agile... is also a vital Reference book and tutorial, if you intend
to do Rails, you need to have it.

Ruby for Rails fills in a lot of blanks, and yes, the discussions in
it about self and several other topics are some of the best and most
often referred to. You'll be glad you bought it. You could jump
straight into Ruby and Rails with only this book, but you should
always build a small library for any language and/or framework,
because one book will answer what another book will not.

If you really need to learn beginning Ruby, go for the book Beginning
Ruby: From Novice to Professional.
It won't really get you to Professional, but it will get you to where
you have at least a basic understanding of a broad number of topics
touched by Ruby.

Also consider the Oreilly books, Ruby Cookbook, and Rails Cookbook.
The Ruby Cookbook unfortuanately doesn't address some of the useful
topics in other language cookbooks (like the PHP book).
Luckily all but maybe 1 of the Ruby books out there are very very
good programming books.

The problem you may eventually encounter is situations where Rails
(or Camping even) are overkill for a web site, and all you need is
simpler stuff. Also, if you are planning to use Ruby technologies for
web sites, investigate hosting services very carefully. Ruby isn't as
widely or well supported by hosting providers as is PHP. What's more,
Rails, like some Python frameworks, is best hosted by companies that
specialize in these kinds of web apps. These kinds of web apps are
best served by having slice hosting or VPS (virtual private server)
hosting. Not the usual shared hosting. Of course, if you can afford
dedicated hosting, that works too.
 
R

Rick DeNatale

+1

I'd really like to see David to rework it into a Ruby-based
introductory programming text.

I'd like to see that too, well unless I beat him to writing one <G>

Actually I like Ruby For Rails, but I'm afraid to say that it's gotten
pretty far behind the current state of Rails.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top