Ruby Metaprogramming

A

Ari Brown

Are there any suggested resources on learning the art of Ruby
metaprogramming?

yea, it's a short message... But a good one nonetheless
~ Ari
Google has been visited.
 
A

Ari Brown

Ruby for Rails, by David Black.

I can buy Ruby for Rails at my local bookstore, but it costs a bunch.
Is it really so good for me to spend $50? I don't exactly have a job
(too young), so take that into account...


Thanks,
~ Ari
English is like a pseudo-random number generator - there are a
bajillion rules to it, but nobody cares.
 
B

Brett Simmers

Ari said:
I can buy Ruby for Rails at my local bookstore, but it costs a bunch.
Is it really so good for me to spend $50? I don't exactly have a job
(too young), so take that into account...


Thanks,
~ Ari
English is like a pseudo-random number generator - there are a
bajillion rules to it, but nobody cares.
I don't know if this is enough of a difference, but it's only $30 at
Amazon, with free shipping:
http://www.amazon.com/Ruby-Rails-Te...0652149?ie=UTF8&s=books&qid=1186184282&sr=8-1

-Brett
 
G

Giles Bowkett

I can buy Ruby for Rails at my local bookstore, but it costs a bunch.
Is it really so good for me to spend $50? I don't exactly have a job
(too young), so take that into account...

I can't really answer the question about whether R4R is worth $50, it
depends what $50 is worth to you. I have a copy of it here on my
shelf, I thought it was worth it. :)

In terms of cheap alternatives, use the Ruby Quiz, and Google, and blogs.

Ola Bini has a good overview on metaprogramming:

http://ola-bini.blogspot.com/2006/09/ruby-metaprogramming-techniques.html

Glenn Vanderburg has a good set of presentation slides:

http://www.vanderburg.org/Speaking/Stuff/oscon05.pdf

I found this stuff just by googling "ruby metaprogramming." There's
plenty of good stuff out there.
 
M

Marcel Molina Jr.

Ola Bini has a good overview on metaprogramming:

http://ola-bini.blogspot.com/2006/09/ruby-metaprogramming-techniques.html

Glenn Vanderburg has a good set of presentation slides:

http://www.vanderburg.org/Speaking/Stuff/oscon05.pdf

Another resource that I haven't noticed mentioned yet is _why's Dwemthy's
Array stuff:
http://whytheluckystiff.net/articles/seeingMetaclassesClearly.html
and
http://poignantguide.net/dwemthy/

Also Jamis wrote about it indirectly in his post on DSLs:
http://weblog.jamisbuck.org/2006/4/20/writing-domain-specific-languages

marcel
 
A

Ari Brown

I can't really answer the question about whether R4R is worth $50, it
depends what $50 is worth to you. I have a copy of it here on my
shelf, I thought it was worth it. :)

In terms of cheap alternatives, use the Ruby Quiz, and Google, and
blogs.

Ola Bini has a good overview on metaprogramming:

http://ola-bini.blogspot.com/2006/09/ruby-metaprogramming-
techniques.html

Glenn Vanderburg has a good set of presentation slides:

http://www.vanderburg.org/Speaking/Stuff/oscon05.pdf

I found this stuff just by googling "ruby metaprogramming." There's
plenty of good stuff out there.

Thanks! I'm going to start a little page of MetaProgramming links
(either generic languages or ruby-specific),

so if anyone has any link or book they'd like to share, I'd be glad
to put it up.

Thanks,
-------------------------------------------------------|
~ Ari
crap my sig won't fit
 
J

John Joyce

Thanks! I'm going to start a little page of MetaProgramming links
(either generic languages or ruby-specific),

so if anyone has any link or book they'd like to share, I'd be glad
to put it up.

Thanks,
-------------------------------------------------------|
~ Ari
crap my sig won't fit
Programming books are expensive, especially when you get one that
turns out to be no good or at least no good for you.
But luckily, Ruby (and Rails) books are always good. I haven't found
a bad one yet.
When they're good, they're worth the price, because you'll keep
looking back to them for information.
 
G

Giles Bowkett

Thanks! I'm going to start a little page of MetaProgramming links
(either generic languages or ruby-specific),

Just to be entirely capricious, there's a totally different way to
take the words "Ruby metaprogramming," which concerns using IRB with
lots of enhancements. A lot of popular Ruby apps have interactive
shells, Ruby itself has one, and if you do a lot in the interactive
shells, you're working in an environment defined by Ruby code. You can
add features to that environment by adding new Ruby code to the Ruby
code which already defines it. So programming your programming
environment in Ruby is one highly productive way to deliberately
misuse the term "Ruby metaprogramming."
 
D

dblack

Hi --

Thanks! I'm going to start a little page of MetaProgramming links (either
generic languages or ruby-specific),

so if anyone has any link or book they'd like to share, I'd be glad to put it
up.

http://dablog.rubypal.com/2007/1/7/meta-shmeta-learning-ruby-horizontally


David

--
* Books:
RAILS ROUTING (new! http://www.awprofessional.com/title/0321509242)
RUBY FOR RAILS (http://www.manning.com/black)
* Ruby/Rails training
& consulting: Ruby Power and Light, LLC (http://www.rubypal.com)
 

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
474,266
Messages
2,571,318
Members
47,998
Latest member
GretaCjy4

Latest Threads

Top