Thursday, May 24, 2007

Standing on the Shoulders of Giants

presented by Adam Keys

Resources:

Web:
http://therealadam.com (personal web site)

Book:
Code Reading

Good Code:
xmlrpc4r - first code he found really readable
authenticated_system.rb
Beast (josh goebel and rick olson) great place to look for best, current idiom
rake (straight-up ruby code)
acts_as_versioned

My Summary:

We spend too much time reading code not to care about improving our code reading skills!

My Notes:

Control your destiny by reading other's code!

think of code reading as spelunking, put on a helmet with a light to get ready!

Navigating the Call Stack
start in routes for rails code

look at url, x-ref with route.rb

check out controller or go right to view

grok any controller filters

grok the controller action
grok the methods the controller calls
??

know what's in the lib and plugins folder
check for observers/validations/callbacks, etc. in models

Ruby Spelunking
-parliament/lib/my_funk
-parliament/lib/my_funk.rb

the magic page variable, how is it implemented?

the magic global variable

No comments: