Skip to content

{ Daily Archives } Wednesday, January 2010

Ruby on Rails shell commands

This is just a reminder to me about commands that I use. rails appname rake –tasks rake db:create rake db:drop rake db:migrate script/generate controller myobject script/generate model Person name:string age:integer script/generate scaffold Person name:string age:integer

Ruby on Rails ORM through ActiveRecord

Rails offers an ORM layer.  This layer is not a very strict layer.  To filter or sort objects, you are actually writing SQL code.  There doesn’t seem to be much complaining in the community about this mis-feature.  In fact in the Agile Web Development with Rails book, the author basically makes snide comments about people [...]

Ruby on Rails Layouts

Site wide layout One common method of creating common look and feels in web development is to split up all the common code into a header file and a footer file and include those files in every single interface page.  This is better than embedding all that html code inside each page, but it is [...]