Articles

60. Ruby Metaclasses Final Episode

In this final episode you will learn how every class in Ruby is a first-class object. We will see how classes and subclasses have metaclasses and how to access them.

Reference: MetaRails - Metaprogramming by example by Nick Sieger RUM - July 25, 2006 

Google it to download the slides. 

Cool Rails SVN tidbit - showing the revision #

If you want to show the SVN Revision number on your page - this helps the test team - add this code to your site:<%= `svn info #{RAILS_ROOT}`.match('Revision.*') %>Those are back-quotes. This will cause a shell command to be run.If you add it to your environment.rb like so:$svn_revision = `svn info #{RAILS_ROOT}`.match('Revision.*')Then it is run when the server starts and you can access it on

Ruby Chops: Blocks and Procs

Download Source Code



59. Ruby Metaclasses part 5

This is the final episode based on Why the luck stiff's "Seeing Metaclasses clearly" article.

This episode ends with an illustration of a powerful metaprogramming concept that every Ruby programmer should know. 

Prerequisite: instance_eval, changing self in Ruby episodes and previous episodes on metaclasses.

 Correction: self inside the Class << self is not the FooSub but is the metaclass of FooSub.

58. Higher Order Procedures in Ruby

A powerful language provides the ability to build abstractions by assigning names to common patterns and then to work in terms of the abstractions directly. In this presentation you will see how Higher-Order Procedures can be used to formulate abstractions in Ruby.

You will learn how to write concise code to become a rockstar Ruby coder.

 Prerequisite: Ruby blocks episodes and the previous episode. 

A Three Finger Salute to Git

David Letterman often asks: Is this anything? And now I ask you.

Consume non rails-style REST API's

ActiveResource is a great concept which consumes rails-style REST API but unfortunately most of the REST API's are not rails-style. This means that very frequently you will end up modifying ActiveResource to consume non rails-style REST API's. This article is about understanding ActiveResource and how to tweak/extend it to consume non rails-style REST API's. We will mainly concentrate on reading data i.e. the GET method.

57. Ruby Metaclasses part 4

In this screencast you will learn about the method lookup and basic concept required for an upcoming episode "Higher Order Procedures in Ruby".

Ruby Chops: using super in inheritance

Source Code



56. Ruby Metaclasses part 3

In this screencast we will continue our exploration of meta classes in Ruby.

David Kaneda’s real nice use of CSS transforms. | Rails Fire

David Kaneda’s real nice use of CSS transforms.

Send to friend



David Kaneda’s real nice use of CSS transforms.