I need to learn

On Mon, Mar 12, 2007 at 10:12:45PM +0900, Rick DeNatale wrote:

I might suggest that “Ruby for Rails” might be a good book to start
with. It covers both Ruby and Rails in a spiral fashion, giving you a
little Ruby, then a little Rails, then going back in more depth.

It doesn’t cover Ruby as deeply as the pickaxe, and it doesn’t cover
Rails as deeply as AWDWR (and it’s based on Rails 1.1 whereas AWDWR
2nd ed is more up-to-date covering the recently released Rails 1.2),
but as an introduction to both Ruby and Rails as a whole it’s probably
not a bad place to start.

Thanks for adding a more experienced perspective on those books. I’ll
add some of the details of that to my store of knowledge.

Now my experience was based on first reading the 1st ed of the pickaxe
on-line, then either the 1st ed of AWDWR or the 2nd ed of the Pickaxe
(or the other way around), then Ruby for Rails and AWDWR 2nd ed (sort
of in parallel). So I don’t really know what it would have been like
to start with Ruby for Rails, any more than someone of my age knows
what it would be like to encounter Star Wars for the first time in the
the order Episode 1, 2, 3, 4, 5, 6.

I imagine it would be a little disorienting, but I’m just guessing.

The short answer: “It depends.”

I think this point is overlooked. Lots of people are learning Ruby,
but where you come to it from is going to shape how you learn it best.

“Ruby for Rails” and “The Ruby Way” are both very good in my opinion.

On Mon, Mar 12, 2007 at 07:20:17PM +0900, Morton G. wrote:

On Mar 12, 2007, at 4:51 AM, John J. wrote:

Let’s just say that irb is worth learning to use and useful to
know. It can be a lot quicker than Creating a new file, changing
permissions on it and executing it.

I think a lot depends on one’s work habits. I have TextMate open all
the time, but not Terminal. So it’s quicker for me to evaluate
snippets in TextMate than to open a terminal window and fire up irb.
There is no need to set permissions to run code from TextMate.

You’re right – it probably does depend to some extent on work habits.
For instance, I typically have several windows open, including both a
window for Vim and others for irb, command line execution, et cetera.

Rick Denatale wrote:

I might suggest that “Ruby for Rails” might be a good book to start
with. It covers both Ruby and Rails in a spiral fashion, giving you a
little Ruby, then a little Rails, then going back in more depth.

It doesn’t cover Ruby as deeply as the pickaxe, and it doesn’t cover
Rails as deeply as AWDWR (and it’s based on Rails 1.1 whereas AWDWR
2nd ed is more up-to-date covering the recently released Rails 1.2),
but as an introduction to both Ruby and Rails as a whole it’s probably
not a bad place to start.

I took a look at “Ruby for Rails” in the bookstore, and the preface says
you need previous experience with Rails. Do you think the book is
appropriate for someone who has no experience with Ruby or with Rails?

I also took a look at the new sitepoint book “Build Your Own Ruby on
Rails Web Applications”(copyright 2007):

http://www.amazon.com/Build-Your-Ruby-Rails-Applications/dp/0975841955

which says it’s for beginners to Ruby and Rails. It gets good reviews
on Amazon. One thing I liked about it: detailed installation
instructions. Not such a big deal for windows users because of one
click installation packages, but there are detailed installation
instructions for Mac OS 10.4, and separate installation instructions for
Linux. It’s true there are installation instructions for Mac OS 10.4 on
the net, but unfortunately I can’t even find the /usr/local directory
where everything is supposed to be installed. Am I supposed to create
that directory? Who knows. I hate installation instructions like that;
you feel lost before you can even start.

On Mar 13, 2007, at 3:48 PM, 7stud 7stud wrote:

Rick Denatale wrote:
… unfortunately I can’t even find the /usr/local directory
where everything is supposed to be installed. Am I supposed to create
that directory? Who knows. I hate installation instructions like
that;
you feel lost before you can even start.

If that kind of stuff scares you, don’t worry, you’re not alone. That
Unix command line stuff IS scary at times, especially in the
beginning. I hate to tell you this, though, but if you’re building
web aplications or even static web sites, you need to learn the Unix
command line stuff. It makes a whole lot of other stuff a lot easier
to do and to understand. It’s vital, but you don’t need to learn all
of it. If you’re on a mac, get the Learning Unix for Mac OS X Tiger
(or whichever version you have) from OReilly. It is a good intro to
that stuff. While you’re at it, UNIX in a Nutshell covers all of it
unix/linux/osx/bsd because it’s all mostly the same, but it also
points out differences where important.
I know, you want to learn Ruby, and Rails, but these sit on top of
some form of unix most of the time, and much of the programming world
is basically built up on unix thinking and traditions (microsoft
stuff aside)

On 3/13/07, John J. [email protected] wrote:

On Mar 13, 2007, at 3:48 PM, 7stud 7stud wrote:

Rick Denatale wrote:
… unfortunately I can’t even find the /usr/local directory

Umm, no I didn’t. 7Stud 7Stud did. Just for the record I do know how
to find the /usr/local directory, and those other things


Rick DeNatale

My blog on Ruby
http://talklikeaduck.denhaven2.com/

Umm, no I didn’t. 7Stud 7Stud did. Just for the record I do know how
to find the /usr/local directory, and those other things

Rick DeNatale

Sorry about that. I got a little over-zealous with the cropping, in a
hurry. wasn’t direct at anybody in particular, at anyone thinking of
web apps and Ruby and Rails as doable with no understanding of *nix.

On 3/13/07, 7stud 7stud [email protected] wrote:

I took a look at “Ruby for Rails” in the bookstore, and the preface says
you need previous experience with Rails. Do you think the book is
appropriate for someone who has no experience with Ruby or with Rails?

Well here’s what it says: "You need to know somthing about the Rails
framework. You don’t need to be a grizzled Rails veteran; you can use
this book as part of your growth as a Rails developer. But you should
have a sense of the realm in whcih Rails operates – or, if you’re
really new to Rails, be willing to combine this book with other
sources of information to get the combined picture by working on
several fronts.

David, actually covers Rails starting from near square one. The book
builds a sample rails app, much like the first section of AWDWR.

I also took a look at the new sitepoint book “Build Your Own Ruby on
Rails Web Applications”(copyright 2007)

One thing I liked about it: detailed installation
instructions. Not such a big deal for windows users because of one
click installation packages, but there are detailed installation
instructions for Mac OS 10.4, and separate installation instructions for
Linux. It’s true there are installation instructions for Mac OS 10.4 on
the net, but unfortunately I can’t even find the /usr/local directory
where everything is supposed to be installed. Am I supposed to create
that directory? Who knows. I hate installation instructions like that;
you feel lost before you can even start.

This IS one thing with Ruby for Rails doesn’t cover. There are
resources to help, such as the rails web-site and the rails mailing
list. On the other hand if you really need such detailed instructions
AWDWR does a very good job of leading you step by step.

One thing I like about AWDWR 2nd ed, as opposed to Ruby for Rails is
that it covers migrations and uses them from the beginning to do
database setup and schema evolution. Ruby for Rails does this using
mysql commands. Some might like that better, but I prefer to stick
with Ruby and Rails for this. My first encounter with Rails was using
the 1st ed of AWDWR, which was before migrations, when I found out
about them later, I slapped my head like those commercials “Wow! I
could have had a V-8” (apologies to those who aren’t attuned to US
commercials, V-8 is a mixed-vegetable juice).


Rick DeNatale

My blog on Ruby
http://talklikeaduck.denhaven2.com/

Umm, no I didn’t. 7Stud 7Stud did. Just for the record I
do know how to find the /usr/local directory, and
those other things

You won’t be able to find in on Mac OS 10.4!

~$ ls -al /usr
total 0
drwxr-xr-x 9 root wheel 306 Feb 11 19:03 .
drwxrwxr-t 31 root admin 1156 Mar 12 16:20 …
drwxr-xr-x 740 root wheel 25160 Feb 26 14:45 bin
drwxr-xr-x 230 root wheel 7820 Feb 11 19:04 include
drwxr-xr-x 273 root wheel 9282 Feb 11 19:25 lib
drwxr-xr-x 72 root wheel 2448 Feb 11 19:03 libexec
drwxr-xr-x 199 root wheel 6766 Feb 11 19:03 sbin
drwxr-xr-x 50 root wheel 1700 Feb 11 19:03 share
drwxr-xr-x 5 root wheel 170 Aug 10 2006 standalone

If anything, you might be a bit lost at times if you ask too many
questions in the first chapter or 2 of Ruby for Rails. When he says a
breadth first approach, he means it. You create a simple rails app
right away, and you don’t get much explanation, so if you start to
tinker you will wonder why things are kind of incomplete. They are.
It is an attempt to take you through the overall process all at once.
Then he breaks it down a bit more. Explaining some things, like how
somethings in Rails are the way they are because of how Ruby can do
things. That’s true. As you get going though, you will want and
should stop and get the Pickaxe book. It really is indispensible. The
only bad thing is that it is not sold as a two volume set rather than
as one behemoth monster that is half reference and half tutorial. It
would be much easier to keep the reference half at home and take the
other with you or vice-versa. (pragmatic does sell pdf versions of
its books though!)

I love this topic being that recently there has been a surge of new Ruby
/ Rails books published. Here are my two cents (and three books) that I
whole heartedly recommend:

  1. Agile Web D. For Rails, 2nd ed.

Yes, I’ve read the comments of “but it’s not RUBY Ruby”, however I
feel that it’s a great intro to practical Ruby as well as exposing you
to a great web development framework. From here, I usually then point
an aspiring mind to . . .

  1. Ruby For Rails

This book is the perfect complement to the Agile book. After gaining
a basic understanding of Rails, you may start asking yourself questions
of “ok, so how does that piece of code REALLY work?” This book is great
for getting into some of the guts of how Rails works as well as straight
Ruby itself. Instead of it just being a reference, the author really
touches upon deeper aspects of Ruby in the abstract, such as why Ruby is
such a great OOPL, the uses of singleton methods, and the dangers /
practical uses of eval. Overall you will gain tons of knowledge of Ruby
through constant rereading of this book.

  1. The Ruby Way

It was a tossup between this and the highly practical “Ruby Cookbook”.
The reason this one wins is that it provides a deeper view into Ruby.
Instead of question -> recipe -> explanation, there’s more of a
conversational / almost philosophical approach to the reading (question
-> solution -> explanation -> further explanation and insite).

Lastly, nothing beats these forums, IRC, and local Ruby meetings. Check
meetup.com or rubygarden to find a group close to you. Probably one of
the friendliest user communities you’ll run by. Have fun!

Best regards,

Eckie

On Tue, Mar 13, 2007 at 10:42:12PM +0900, Rick DeNatale wrote:

you feel lost before you can even start.

This IS one thing with Ruby for Rails doesn’t cover. There are
resources to help, such as the rails web-site and the rails mailing
list. On the other hand if you really need such detailed instructions
AWDWR does a very good job of leading you step by step.

I tend to feel that the appropriate development platform for any
non-.NET and non-ColdFusion web development is a unixlike OS. For
people learning from their homes, then, either Linux or *BSD is probably
what you should be learning. Yes, it’s entirely possible to learn on MS
Windows, and I’m fully aware that it’s not always practical to get a new
OS up and running, but it’s important enough so that if you have
reasonable opportunity to do so, you should definitely consider getting
some kind of free unix running and use that.

One reason is that in deployment Rails benefits from a unixy
environment. For instance, remote access is better protected by SFTP
than FTP, and free unices provide that capability by default whereas
with MS Windows setting up an SSH server to handle SFTP is a bit of a
chore. It’s also the case that shared hosting solutions offering Rails
are, as far as I’ve seen thus far, all Linux and FreeBSD systems.

One of the best advantages to learning Rails on a free unix platform,
though, is installation. When I first got Agile Web D. with
Rails, I read through the section on installation – then I ignored it,
and typed in “apt-get install rails” at the command line. Voila,
installed.

One thing I like about AWDWR 2nd ed, as opposed to Ruby for Rails is
that it covers migrations and uses them from the beginning to do
database setup and schema evolution. Ruby for Rails does this using
mysql commands. Some might like that better, but I prefer to stick
with Ruby and Rails for this. My first encounter with Rails was using
the 1st ed of AWDWR, which was before migrations, when I found out
about them later, I slapped my head like those commercials “Wow! I
could have had a V-8” (apologies to those who aren’t attuned to US
commercials, V-8 is a mixed-vegetable juice).

I have the first edition, so unless you’re talking about migrating web
applications from other languages/frameworks to Rails, I’m afraid I
don’t know what you’re talking about at first glance.

On Wed, Mar 14, 2007 at 01:24:31AM +0900, Eckie S. wrote:

Lastly, nothing beats these forums, IRC, and local Ruby meetings. Check
meetup.com or rubygarden to find a group close to you. Probably one of
the friendliest user communities you’ll run by. Have fun!

Alas, I’ve been searching for a RUG near me, and there seems to be
nothing closer than an hour drive away. I’m not dedicated enough right
now to drive two hours for a RUG meeting, which means I’m definitely not
dedicated enough to start a RUG myself. C’est la vie.

On the other hand, LUGs (Linux User Groups) might put you in touch with
some Rubyists in your area. It might be worth checking into, even if
you don’t have any nearby RUGs.

Umm, no I didn’t. 7Stud 7Stud did. Just for the record I
do know how to find the /usr/local directory, and
those other things

You won’t be able to find in on Mac OS 10.4!

You just create it if it isn’t there.
Very simple.
This makes it easy to follow standard installations elsewhere as well.
It also makes it real easy to delete everything if you want/need to.
Just need to learn a little about Bash and your $PATH
be careful, the $PATH in your shell can be loaded from multiple dot
files.
They are standardized. They do load in a particular order. If you
have modified your $PATH already in one of the dot files, you may
need to care where you modify it again.
(again you do need some Unix skill or references if you don’t have it)
(again the reason I recommend the OReilly Unix in a Nutshell, they
give a good and fast rundown on the Bash shell. The Linux in a
Nutshell book is almost identical, but doesn’t cover the differences
among nixes)

You will also be glad to have a little MySQL (or the database of your
choice) under your belt or in your library. Sorry, but there are no
easy magic bullets for everything.

7stud 7stud wrote:

This makes it easy to follow standard installations elsewhere as well.
Nutshell book is almost identical, but doesn’t cover the differences
figuring out all the errors has taught me a lot. The problem I find is
directory OS 10.4.7 looks to instead. I scoured google and I can’t find

$ cd /usr
usr$ ls -l
total 0
drwxr-xr-x 8 root wheel 272 Nov 18 16:50 X11R6
drwxr-xr-x 742 root wheel 25228 Feb 17 17:25 bin
drwxr-xr-x 232 root wheel 7888 Mar 20 2006 include
drwxr-xr-x 270 root wheel 9180 Mar 6 20:13 lib
drwxr-xr-x 71 root wheel 2414 Oct 1 12:09 libexec
drwxr-xr-x 8 root wheel 272 Dec 18 2005 local
drwxr-xr-x 205 root wheel 6970 Nov 28 21:41 sbin
drwxr-xr-x 48 root wheel 1632 Mar 19 2006 share
drwxr-xr-x 3 root wheel 102 Mar 24 2005 standalone

Timothy H. wrote:

usr$ ls -l
drwxr-xr-x 8 root wheel 272 Dec 18 2005 local

Thanks

If you’re using OS X, 10.4.9 came out today.
But more importantly, check out the HiveLogic site.
www.hivelogic.com
They’ve got lots of good info on installation of Ruby and Rails an so
on.
Just be careful, they have multiple versions of the install tutorial,
some are older than others, so if you reach the site via a link or
search engine, you might just get an out-of-date version of the install.

Frustration is part of the process with learning unix and using it at
the same time. What you soon discover is that it is a miracle that
all this stuff (or any application) works because there are so many
dependencies and things can be different from machine to machine.
Then again you might start to understand why commercial software is
so bloated these days… (they include everything they didn’t write,
but use)

John J. wrote:

Umm, no I didn’t. 7Stud 7Stud did. Just for the record I
do know how to find the /usr/local directory, and
those other things

You won’t be able to find it on Mac OS 10.4!

You just create it if it isn’t there.
Very simple.
This makes it easy to follow standard installations elsewhere as well.
It also makes it real easy to delete everything if you want/need to.
Just need to learn a little about Bash and your $PATH
be careful, the $PATH in your shell can be loaded from multiple dot
files.
They are standardized. They do load in a particular order. If you
have modified your $PATH already in one of the dot files, you may
need to care where you modify it again.
(again you do need some Unix skill or references if you don’t have it)
(again the reason I recommend the OReilly Unix in a Nutshell, they
give a good and fast rundown on the Bash shell. The Linux in a
Nutshell book is almost identical, but doesn’t cover the differences
among nixes)

You will also be glad to have a little MySQL (or the database of your
choice) under your belt or in your library. Sorry, but there are no
easy magic bullets for everything.

I’m about half way through the Wrox book “Beginning Unix”, which has so
many omissions and errors, I would not recommend it to anyone–although
figuring out all the errors has taught me a lot. The problem I find is
that there are enough differences between Unix and OS 10.4.7, that I
never know whether a missing ‘thing’ in OS X should be created or
whether the Mac uses something else to do the same thing. For instance,
crond. That daemon isn’t present on OS X 10.4.7. Should I start it?
No! Mac uses a new process called lauchd to control all processes in a
methodical fashion–instead of the adhoc patch on patch on patch mess
that Unix has evolved into(that from an article I found praising
launchd, which Apple made open source).

So, when I can’t find /usr/local, I wonder if there is some other
directory OS 10.4.7 looks to instead. I scoured google and I can’t find
ANY mention of /usr/local not being present in OS 10.4.7.

You just create it if it isn’t there.
Very simple.

What permissions does it need?

John J. wrote:

If you’re using OS X, 10.4.9 came out today.
But more importantly, check out the HiveLogic site.
www.hivelogic.com
They’ve got lots of good info on installation of Ruby and Rails an so
on.
Just be careful, they have multiple versions of the install tutorial,
some are older than others, so if you reach the site via a link or
search engine, you might just get an out-of-date version of the install.

Frustration is part of the process with learning unix and using it at
the same time. What you soon discover is that it is a miracle that
all this stuff (or any application) works because there are so many
dependencies and things can be different from machine to machine.
Then again you might start to understand why commercial software is
so bloated these days… (they include everything they didn’t write,
but use)

Thanks, I’ve looked around over there.

The downloads for the new OS’s are something like 3 days long for me, so
I’m not too keen on upgrading.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs