<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-16576374</id><updated>2012-02-16T11:02:24.462-08:00</updated><category term='podcast'/><category term='installation mongrel windows'/><category term='installation'/><category term='plugin'/><category term='tool'/><category term='ajax'/><category term='rails'/><category term='tutorial'/><category term='deployment'/><category term='windows'/><category term='migration'/><category term='rails hosting'/><category term='info'/><category term='netbeans6'/><category term='ide'/><category term='database'/><category term='tutorial ruby'/><title type='text'>Learning Ruby on Rails</title><subtitle type='html'>This blog is for me to put down little snippet of information I gather while I learn Ruby on Rails.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>65</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-16576374.post-7877637562495825525</id><published>2008-05-13T22:21:00.000-07:00</published><updated>2008-05-13T22:27:59.763-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rails hosting'/><title type='text'>Dreamhost added ability to host Rails app using Passenger</title><content type='html'>I just saw this, &lt;a href="http://blog.dreamhost.com/2008/05/13/passenger-for-ruby-on-rails/"&gt;Introducing Passenger for Ruby on Rails&lt;/a&gt;, on Dreamhost Blog. This should make deploying Rails applications on Dreamhost really simple now.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.modrails.com/"&gt;Passenger&lt;/a&gt; is mod_rails for Apache, as stated on their website. Maybe now is the time for me to give Dreamhost a try. I was thinking of installing Passenger on a VPS I use for testing purpose.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7877637562495825525?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7877637562495825525/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7877637562495825525' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7877637562495825525'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7877637562495825525'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/05/dreamhost-added-ability-to-host-rails.html' title='Dreamhost added ability to host Rails app using Passenger'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-1767454220748190734</id><published>2008-04-02T18:47:00.000-07:00</published><updated>2008-04-02T18:56:22.723-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rails'/><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Rails is moving over to Github</title><content type='html'>It looks like keeping up with edge Rails for Windows' users will get harder in the very near future. Here is &lt;a href="http://weblog.rubyonrails.com/2008/4/2/rails-is-moving-from-svn-to-git"&gt;the post&lt;/a&gt; announcing the move from using SVN to Git. I look into using Git on Windows before but it doesn't work well on Windows. It works if you run it on top of cygwin. Otherwise, it is a no go for now.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-1767454220748190734?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/1767454220748190734/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=1767454220748190734' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1767454220748190734'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1767454220748190734'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/04/rails-is-moving-over-to-github.html' title='Rails is moving over to Github'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2667014695512099812</id><published>2008-03-26T10:23:00.000-07:00</published><updated>2008-03-26T10:38:51.232-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='windows'/><title type='text'>Developing Ruby on Windows Platform</title><content type='html'>There is an interesting discussion over at Ruby Inside regarding "&lt;a href="http://www.rubyinside.com/is-windows-a-first-class-platform-for-ruby-823.html"&gt;Is Windows a First Class Platform for Ruby&lt;/a&gt;"? I think there are two parts to this question.&lt;br /&gt;&lt;br /&gt;Windows is definitely viable as a development platform using Ruby. I build and deployed a Rails website using Windows as the development platform. I had a few problems which I was able to overcome by googling around for a patch or two. No show stopper for sure. All the gems I need were working fine on Windows. A big thanks to those maintainers that kept their gems multi-platforms.&lt;br /&gt;&lt;br /&gt;Windows as a deployment platform. I think this is where I draw the line. I didn't even think for a second about deploying the site on Windows. It is definitely not an option at all. Although, I am looking forward to &lt;a href="http://www.ironruby.net/"&gt;IronRuby&lt;/a&gt; and its support for Rails. I know one of their goal is to be able to run Rails. IIS 7 is looking quite nice.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2667014695512099812?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2667014695512099812/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2667014695512099812' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2667014695512099812'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2667014695512099812'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/03/developing-ruby-on-windows-platform.html' title='Developing Ruby on Windows Platform'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4477430738663548860</id><published>2008-02-04T15:31:00.000-08:00</published><updated>2008-02-04T16:39:32.421-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rails'/><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>form_remote_tag with ajax and none ajax action</title><content type='html'>Does anyone else having the same problem as I do when trying to set the url for AJAX and none AJAX actions for the form_remote_tag? I always seem to forget how to do this. It always take me a couple of tries to get this right. Anyway, I am putting the correct way to do this here so I come back later when I forget.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;  &amp;lt;% form_remote_tag :url =&gt; {:controller =&gt; '/posts', :action =&gt; 'view'},&lt;br /&gt;:html =&gt; {:action =&gt; {:controller =&gt; '/posts', :action =&gt; 'view', :id =&gt; @id}} do %&gt;&lt;br /&gt;    &amp;lt;%= submit_tag 'View' -%&gt;&lt;br /&gt;  &amp;lt% end %&gt;&lt;br /&gt;&lt;/pre&gt;&lt;pre&gt;&lt;br /&gt;&amp;lt;form action="/posts/view/1" method="post" &lt;br /&gt;onsubmit="new Ajax.Request('/posts/view/1', &lt;br /&gt;{asynchronous:true, evalScripts:true, parameters:Form.serialize(this)}); return false;"&gt;&lt;br /&gt;    &amp;lt;input type="submit" value="View" /&gt;&lt;br /&gt;&amp;lt;/form&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4477430738663548860?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4477430738663548860/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4477430738663548860' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4477430738663548860'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4477430738663548860'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/02/formremotetag-with-ajax-and-none-ajax.html' title='form_remote_tag with ajax and none ajax action'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2380737550421643344</id><published>2008-01-30T11:25:00.000-08:00</published><updated>2008-01-30T11:33:27.113-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>What happened to nbrubyide daily build?</title><content type='html'>What happened to daily build of nbrubyide? I have been checking the last few days and there is no new build. I am so used to getting my morning nbrubyide fix. This is not a complain. I am just wondering.&lt;br /&gt;&lt;br /&gt;Here is where I go to download the latest build.&lt;br /&gt;http://deadlock.netbeans.org/hudson/job/ruby/changes&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2380737550421643344?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2380737550421643344/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2380737550421643344' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2380737550421643344'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2380737550421643344'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/01/what-happened-to-nbrubyide-daily-build.html' title='What happened to nbrubyide daily build?'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3726834606180202881</id><published>2008-01-17T23:51:00.000-08:00</published><updated>2008-01-17T23:57:41.504-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial ruby'/><title type='text'>Converts a comma separated string of numbers into an array of integers</title><content type='html'>This is all there is to convert a string of comma separated integers to an array of integers.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&gt;&gt; "1,24,53,6,23,6,5".split(",").collect{ |s| s.to_i }&lt;br /&gt;=&gt; [1, 24, 53, 6, 23, 6, 5]&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;This is why Ruby is so fun to use. Is there a shorter way to do this than what I have?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3726834606180202881?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3726834606180202881/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3726834606180202881' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3726834606180202881'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3726834606180202881'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/01/converts-comma-separated-string-of.html' title='Converts a comma separated string of numbers into an array of integers'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-6013611323462532064</id><published>2008-01-08T21:45:00.000-08:00</published><updated>2008-01-08T21:58:38.800-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial ruby'/><title type='text'>Expose Module methods as Instance and Class methods</title><content type='html'>Have you ever wondered how to include a Module and has its methods be available as instance methods and class methods? I certainly did and after doing a little research I figured out a way to do this in Ruby. For the experience Ruby programmers out there, this is probably very obvious but for those that haven't completely figured out Class object and instance of a class then this should help a little. Or totally confused you.&lt;br /&gt;&lt;br /&gt;I don't know whether it is wise to do this but at least it is possible to do. Anyway, enough talking. Here is the code in all it (not so) glory.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;module Methods&lt;br /&gt; def self.included(base)&lt;br /&gt;  # add methods in ClassMethods into the meta class&lt;br /&gt;  base.extend(ClassMethods)&lt;br /&gt; end&lt;br /&gt; &lt;br /&gt; def hi&lt;br /&gt;  # accessing the meta class to call the&lt;br /&gt;  # real method&lt;br /&gt;  class &lt;&lt; self&lt;br /&gt;   self.hi&lt;br /&gt;  end&lt;br /&gt; end&lt;br /&gt; &lt;br /&gt; def bye&lt;br /&gt;  class &lt;&lt; self&lt;br /&gt;   self.bye&lt;br /&gt;  end&lt;br /&gt; end&lt;br /&gt;&lt;br /&gt; module ClassMethods&lt;br /&gt;  def hi&lt;br /&gt;   puts "Hello"&lt;br /&gt;  end&lt;br /&gt;  &lt;br /&gt;  def bye&lt;br /&gt;   puts "Good Bye"&lt;br /&gt;  end&lt;br /&gt; end&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;class Greeting&lt;br /&gt; include Methods&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;# Calling Instance methods here&lt;br /&gt;Greeting.new().hi&lt;br /&gt;Greeting.new().bye&lt;br /&gt;&lt;br /&gt;# calling Class methods here&lt;br /&gt;Greeting.hi&lt;br /&gt;Greeting.bye&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-6013611323462532064?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/6013611323462532064/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=6013611323462532064' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6013611323462532064'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6013611323462532064'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/01/expose-module-methods-as-instance-and.html' title='Expose Module methods as Instance and Class methods'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-6185365502726595129</id><published>2008-01-05T03:40:00.000-08:00</published><updated>2008-01-05T03:44:30.059-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Encryption Data in Ruby using OpenSSL</title><content type='html'>I had been searching the web for a way to encrypt some data for my Rails project for a while and I finally found something that I could use. &lt;a href="http://stuff-things.net/2007/06/11/encrypting-sensitive-data-with-ruby-on-rails/"&gt;Encrypting Sensitive Data with Ruby (on Rails)&lt;/a&gt; has straight forward instructions on how to encrypt and decrypt data using OpenSSL in Ruby.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-6185365502726595129?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/6185365502726595129/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=6185365502726595129' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6185365502726595129'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6185365502726595129'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/01/encryption-data-in-ruby-using-openssl.html' title='Encryption Data in Ruby using OpenSSL'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-5609720759896610731</id><published>2008-01-04T13:55:00.000-08:00</published><updated>2008-01-04T14:33:05.993-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rails'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>adding special helpers</title><content type='html'>I was cleaning up my view and decided that I want to add two helpers, display_if and display_unless to help clean up the view.&lt;br /&gt;&lt;br /&gt;Instead of doing:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;% if @login %&gt;&lt;br /&gt;  Hello &lt;%= @user_name -%&gt;.&lt;br /&gt;&lt;% end %&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;It would be like this:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;% display_if @login %&gt;&lt;br /&gt;  Hello &lt;%= @user_name -%&gt;.&lt;br /&gt;&lt;% end %&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;I came from the Asp.Net world so writing a custom control to do this is not easy. I was expecting it to be difficult in Rails also but it turned out to be very simple.&lt;br /&gt;&lt;br /&gt;It took me less than 10 minutes to figure it out from not knowing how to do it at all. Hopefully, I am doing it correctly.&lt;br /&gt;Here is the code for the two helpers. Just put them in your application_helper.rb file.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;  def display_if(condition, &amp;block)&lt;br /&gt;    raise ArgumentError, "Missing block" unless block_given?&lt;br /&gt;&lt;br /&gt;    if condition&lt;br /&gt;      output = capture(&amp;block)&lt;br /&gt;      concat(output, block.binding)&lt;br /&gt;    end&lt;br /&gt;  end&lt;br /&gt;  def display_unless(condition, &amp;block)&lt;br /&gt;    raise ArgumentError, "Missing block" unless block_given?&lt;br /&gt;    &lt;br /&gt;    unless condition&lt;br /&gt;      output = capture(&amp;block)&lt;br /&gt;      concat(output, block.binding)&lt;br /&gt;    end&lt;br /&gt;  end&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-5609720759896610731?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/5609720759896610731/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=5609720759896610731' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5609720759896610731'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5609720759896610731'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2008/01/adding-special-helpers.html' title='adding special helpers'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2403885174811692431</id><published>2007-12-30T13:37:00.000-08:00</published><updated>2007-12-30T14:04:09.503-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='info'/><title type='text'>Understanding include and extend in Ruby</title><content type='html'>I was watching a presentation by Dave Thomas called, "&lt;a href="http://www.infoq.com/presentations/metaprogramming-ruby"&gt;MetaProgramming - Extending Ruby for Fun and Profit&lt;/a&gt;", and realized that my understanding of include and extend is mixed up.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;My Wrong Understanding&lt;/span&gt;&lt;br /&gt;&lt;strike&gt;I thought "extend" will add methods from a module into a class as instance methods and "include" will add them as class methods.&lt;/strike&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Correct Understand:&lt;/span&gt;&lt;br /&gt;"extend" adds methods from a module into a class as class methods.&lt;br /&gt;"include" adds methods from a module into a class as instance methods.&lt;br /&gt;&lt;br /&gt;It is quite easy to demonstrate this actually.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;module SomeModule&lt;br /&gt;  def hi&lt;br /&gt;    puts "hello"&lt;br /&gt;  end&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;class ExtendSample&lt;br /&gt;  extend SomeModule&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;ExtendSample.hi&lt;br /&gt;&lt;br /&gt;class IncludeSample&lt;br /&gt;  include SomeModule&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;IncludeSample.new.hi&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2403885174811692431?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2403885174811692431/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2403885174811692431' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2403885174811692431'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2403885174811692431'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/12/understanding-include-and-extend-in.html' title='Understanding include and extend in Ruby'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3589973616205463603</id><published>2007-12-17T18:03:00.000-08:00</published><updated>2007-12-17T18:22:59.227-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='migration'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>AUTO_INCREMENT MySQL</title><content type='html'>There is a bug in MySQL that reset AUTO_INCREMENT if an index is added and the table is empty. I found a &lt;a href="http://dev.rubyonrails.org/ticket/8918"&gt;ticket&lt;/a&gt; regarding this issue in Ruby on Rails' bug tracker but it won't be fix because it is a MySQL bug.&lt;br /&gt;&lt;br /&gt;Anyway, I reset AUTO_INCREMENT to my desire value after adding indexes to the table and  that seems to work. Just remember to not add anymore indexes to the table after you set the AUTO_INCREMENT value or else it will be reset again.&lt;br /&gt;&lt;br /&gt;Here is how to set the value manually.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;execute "ALTER TABLE table1 AUTO_INCREMENT = 100"&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3589973616205463603?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3589973616205463603/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3589973616205463603' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3589973616205463603'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3589973616205463603'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/12/autoincrement-mysql.html' title='AUTO_INCREMENT MySQL'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3510837806122800558</id><published>2007-12-14T00:26:00.001-08:00</published><updated>2007-12-14T00:36:11.754-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='migration'/><category scheme='http://www.blogger.com/atom/ns#' term='rails'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>added method to help create and drop foreign key</title><content type='html'>We have a naming convention at my work place for foreign key so I made two methods to help in the creation and dropping of foreign key. I made them because I got tired of typing out the query everytime.&lt;br /&gt;&lt;br /&gt;We name our foreign key like this: fk_table_column_reference_table_column. So a foreign key from a "users" table to the "employers" table would look like this. fk_users_employer_id.&lt;br /&gt;&lt;br /&gt;This is how you call the method to create a foreign key.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;create_foreign_key(:users, :employer_id, :employers, :id)&lt;br /&gt;drop_foreign_key(:users, :employer_id)&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;  def create_foreign_key(table, column, foreign_table, foreign_column)&lt;br /&gt;    execute "ALTER TABLE #{table.to_s} ADD CONSTRAINT fk_#{table.to_s}_#{column.to_s} FOREIGN KEY (#{column.to_s}) REFERENCES #{foreign_table}(#{foreign_column})"&lt;br /&gt;  end&lt;br /&gt;&lt;br /&gt;  def drop_foreign_key(table, column)&lt;br /&gt;    execute "ALTER TABLE #{table.to_s} DROP FOREIGN KEY fk_#{table.to_s}_#{column.to_s}"&lt;br /&gt;  end&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3510837806122800558?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3510837806122800558/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3510837806122800558' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3510837806122800558'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3510837806122800558'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/12/added-method-to-help-create-and-drop.html' title='added method to help create and drop foreign key'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2643911143807000905</id><published>2007-12-10T13:58:00.000-08:00</published><updated>2007-12-10T14:22:59.218-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='netbeans6'/><title type='text'>NetBeans 6 - Out of Memory Exception</title><content type='html'>Lately, I have been getting Out of Memory Exception every time NetBeans load up. This is the exception message, "java.lang.OutOfMemoryError: Java heap space". I am using the daily build of the custom ide for Ruby development.&lt;br /&gt;&lt;br /&gt;I fixed the problem by setting the max heap size to a 512 MB. This is how I start the ide.&lt;br /&gt;&lt;br /&gt;nbrubyide.exe -J-Xmx512m&lt;br /&gt;&lt;br /&gt;UPDATE: I just found out that I can set the max heap size in the nbrubyide.conf file. It is in the etc directory under c:\nbrubyide &lt;br /&gt;I modified it to&lt;br /&gt;&lt;br /&gt;default_options="-J-Xms24m -J-Xmx256m"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2643911143807000905?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2643911143807000905/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2643911143807000905' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2643911143807000905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2643911143807000905'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/12/netbeans-6-out-of-memory-exception.html' title='NetBeans 6 - Out of Memory Exception'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-7929902105128755648</id><published>2007-12-07T13:23:00.000-08:00</published><updated>2007-12-07T13:26:37.687-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rails'/><title type='text'>Rails 2.0.1 is out</title><content type='html'>I am sure this is all over the web but Rails 2.0.1 is out and here is the &lt;a href="http://weblog.rubyonrails.org/2007/12/7/rails-2-0-it-s-done"&gt;announcement&lt;/a&gt;. I probably won't use it for my current project until after we do a release.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7929902105128755648?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7929902105128755648/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7929902105128755648' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7929902105128755648'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7929902105128755648'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/12/rails-201-is-out.html' title='Rails 2.0.1 is out'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-242109563946880783</id><published>2007-12-03T14:52:00.001-08:00</published><updated>2007-12-03T15:03:28.446-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='installation mongrel windows'/><title type='text'>Mongrel installed in wrong location?</title><content type='html'>I just reinstall my rails stack to use ruby 1.8.6 and mongrel wouldn't start. I kept getting this error instead.&lt;br /&gt;&lt;br /&gt;C:/languages/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require': no such file to load -- C:/languages/ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.1-x86-mswin32-60/lib/mongrel/init.rb (MissingSourceFile)&lt;br /&gt;&lt;br /&gt;Which is strange since Mongrel is one of the install gem when I do gem list. Here are my install gems.&lt;br /&gt;&lt;br /&gt;*** LOCAL GEMS ***&lt;br /&gt;&lt;br /&gt;actionmailer (1.3.6)&lt;br /&gt;actionpack (1.13.6)&lt;br /&gt;actionwebservice (1.2.6)&lt;br /&gt;activerecord (1.15.6)&lt;br /&gt;activesupport (1.4.4)&lt;br /&gt;capistrano (2.1.0)&lt;br /&gt;cgi_multipart_eof_fix (2.5.0)&lt;br /&gt;gem_plugin (0.2.3)&lt;br /&gt;highline (1.4.0)&lt;br /&gt;mongrel (1.1.1)&lt;br /&gt;needle (1.3.0)&lt;br /&gt;net-sftp (1.1.0)&lt;br /&gt;net-ssh (1.1.2)&lt;br /&gt;rails (1.2.6)&lt;br /&gt;rake (0.7.3)&lt;br /&gt;&lt;br /&gt;I can see mongrel is installed under mongrel-1.1.1-mswin32 but the system was trying to look for mongrel under mongrel-1.1.1-x86-mswin32-60.&lt;br /&gt;&lt;br /&gt;I rename my mongrel directory to mongrel-1.1.1-x86-mswin32-60 and everything works. I wonder if I did something wrong or Mongrel just installed in the wrong directory. I am using gem 0.9.5 and it just figures out the correct version of mongrel and install it by itself so I didn't have the chance to pick which version of mongrel I wanted to install.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-242109563946880783?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/242109563946880783/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=242109563946880783' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/242109563946880783'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/242109563946880783'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/12/mongrel-installed-in-wrong-location.html' title='Mongrel installed in wrong location?'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4595842668278396870</id><published>2007-07-17T13:58:00.000-07:00</published><updated>2007-07-17T14:07:31.849-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='netbeans6'/><title type='text'>NetBeans IDE 6.0 M10 is out</title><content type='html'>Netbeans 6.0 M10 is out. There are many editing and debugging improvement for RHTML files. Here is the &lt;a href="http://wiki.netbeans.org/wiki/view/NewAndNoteWorthyMilestone10#section-NewAndNoteWorthyMilestone10-Ruby"&gt;new feature sections for Ruby development&lt;/a&gt;.&lt;br /&gt;&lt;ul&gt;&lt;br /&gt;&lt;li&gt;Find Usages&lt;/li&gt;&lt;li&gt;Rename Refactoring&lt;/li&gt;&lt;li&gt;RHTML support&lt;ul&gt;&lt;li&gt;Debugging (breakpoints, stepping etc. in RHTML files)&lt;/li&gt;&lt;li&gt;Code completion&lt;/li&gt;&lt;li&gt;Go to declaration&lt;/li&gt;&lt;li&gt;Find Usages&lt;/li&gt;&lt;li&gt;Rename&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;li&gt;Improved code completion - attributes, Rails migrations, models and views now include all the expected methods, etc.&lt;/li&gt;&lt;li&gt;Enhanced RDoc rendering; embedded Ruby and RHTML code fragments are now syntax highlighted&lt;/li&gt;&lt;li&gt;Debugger enhancements (global vars, watch view, locals view)&lt;/li&gt;&lt;li&gt;Encoding support (projects now have an encoding property)&lt;/li&gt;&lt;li&gt;Basic RSpec and ZenTest support (More Info), basic RJS support&lt;/li&gt;&lt;li&gt;JRuby 1.0 is bundled &lt;/li&gt;&lt;br /&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4595842668278396870?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4595842668278396870/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4595842668278396870' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4595842668278396870'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4595842668278396870'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/07/netbeans-ide-60-m10-is-out.html' title='NetBeans IDE 6.0 M10 is out'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4613786769027095817</id><published>2007-07-17T13:41:00.000-07:00</published><updated>2007-07-17T13:56:35.668-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Developing ROR using Emacs</title><content type='html'>I saw a few screencast on using Emacs to do ROR development but I was not able to setup emacs to try it out until I saw this five part series on setting up Emacs for Ruby on Rails development from &lt;a href="http://sodonnell.wordpress.com/"&gt;Software bits and pieces&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://sodonnell.wordpress.com/the-emacs-newbie-guide-for-rails/"&gt;http://sodonnell.wordpress.com/the-emacs-newbie-guide-for-rails/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;After following guide step by steps I was able to get emacs up and running for developing ROR. Initially emacs started up with an error and it wasn't able to go into ROR mode. I found out I was missing inf-ruby which you can get it &lt;a href="http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/misc/inf-ruby.el?view=co"&gt;here&lt;/a&gt;. If you following the tutorial then put this file in your c:/emacs-22.1/includes/ directory. After putting the file there, everything works.&lt;br /&gt;&lt;br /&gt;I found another site, &lt;a href="http://www.credmp.org/"&gt;credmp&lt;/a&gt;,  also with instructions on how to setup emacs for ROR development. &lt;a href="http://www.credmp.org/index.php/2006/11/28/ruby-on-rails-and-emacs/"&gt;Ruby On Rails and Emacs&lt;/a&gt; It also list out the snippets that the emacs-rails supports.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4613786769027095817?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4613786769027095817/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4613786769027095817' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4613786769027095817'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4613786769027095817'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/07/developing-ror-using-emacs.html' title='Developing ROR using Emacs'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-530424820572377661</id><published>2007-07-02T22:05:00.000-07:00</published><updated>2007-07-02T22:11:24.704-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='info'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Build FaceBook Application using Rails</title><content type='html'>Here are links to two blog articles on how to build FaceBook application using Rails.&lt;br /&gt;&lt;br /&gt;From GIANT ROBOTS SMASHING INTO OTHER GIANT ROBOTS:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://giantrobots.thoughtbot.com/2007/6/14/fist-in-your-facebook"&gt;fist in your facebook&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;From Liverail &amp;gt;&amp;gt; Rails with currents:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.liverail.net/articles/2007/6/29/tutorial-on-developing-a-facebook-platform-application-with-ruby-on-rails"&gt;Tutorial on developing a Facebook platform application with Ruby On Rails&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-530424820572377661?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/530424820572377661/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=530424820572377661' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/530424820572377661'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/530424820572377661'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/07/build-facebook-application-using-rails.html' title='Build FaceBook Application using Rails'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-9211902456422863565</id><published>2007-06-19T15:24:00.000-07:00</published><updated>2007-06-19T15:36:11.830-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Where to put the code</title><content type='html'>That is the question I ask all the time while developing in Rails. Should I put the code in the helper or in the model or in the controller itself. I guess I need to find some advance Rails reading material. On that note, &lt;a href="http://www.robbyonrails.com/"&gt;Roby on Rails&lt;/a&gt; has a collection of links to making the model fat and the controller skinny. &lt;a href="http://www.robbyonrails.com/articles/2007/06/19/put-your-controllers-on-a-diet-already"&gt;Put Your Controller on a Diet already!&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;After reading those blog posts, I am seeing myself putting some serious time in slim up my controllers. They are a little on the heavy side for sure.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-9211902456422863565?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/9211902456422863565/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=9211902456422863565' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/9211902456422863565'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/9211902456422863565'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/06/where-to-put-code.html' title='Where to put the code'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2648989317439329496</id><published>2007-05-08T12:43:00.000-07:00</published><updated>2007-05-08T13:11:50.878-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>observe_field and radio_button</title><content type='html'>I had a group of radio buttons that I wanted to trigger some action when one of the button is selected. I setup an observe_field for each radio button but it didn't work. You can't specify observe_field to monitor a group of radio buttons. It would only monitor the first button. Actually, let me clarify that statement. It would work the first time a user click on the button but then subsequence click would not register as something has changed. Apparently, it keeps the last value and when the radio button is selected again, the last value and the current value is the same. That result in a no change. I ended up using onclick with remote_function to trigger the change event.&lt;br /&gt;&lt;br /&gt;This is what I had and it doesn't work.&lt;br /&gt;&lt;pre&gt;&amp;lt;%= radio_button_tag 'ship_method', 'pickup', :checked =&gt; true -%&amp;gt; Pickup&lt;br /&gt;&lt;br /&gt;&amp;lt;%= radio_button_tag 'ship_method', 'deliver' -%&amp;gt; Deliver&lt;br /&gt;&lt;br /&gt;&amp;lt;%= observe_field 'ship_method_pickup',&lt;br /&gt;:url =&amp;gt; { :controller =&gt; 'checkout', :action =&gt; 'ship_method_select' },&lt;br /&gt;:on =&amp;gt; 'click', :with =&gt; 'method' -%&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;%= observe_field 'ship_method_deliver',&lt;br /&gt;:url =&amp;gt; { :controller =&gt; 'checkout', :action =&gt; 'ship_method_select' },&lt;br /&gt;:on =&amp;gt; 'click', :with =&gt; 'method' -%&amp;gt;&lt;br /&gt;&lt;/pre&gt;This is what I ended up with&lt;br /&gt;&lt;pre&gt;&amp;lt;input type="radio" name='ship_method' id='ship_method_pickup'&lt;br /&gt; checked="checked" value="pickup"&lt;br /&gt;onclick="&amp;lt;%=&lt;br /&gt;remote_function(&lt;br /&gt;:url =&amp;gt; {:controller =&gt; 'checkout', :action =&amp;gt; 'ship_method_select', :method =&amp;gt; 'pickup'}&lt;br /&gt;)-%&amp;gt;" /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2648989317439329496?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2648989317439329496/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2648989317439329496' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2648989317439329496'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2648989317439329496'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/05/observefield-and-radiobutton.html' title='observe_field and radio_button'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-9135292809677306194</id><published>2007-05-07T00:55:00.000-07:00</published><updated>2007-05-08T13:58:47.306-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ajax'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>How to pass a class or id to link_to_remote</title><content type='html'>This does seem like a really simple thing now that I figured out how to do it.&lt;br /&gt;&lt;pre&gt;&amp;lt;%= link_to_remote 'Name',&lt;br /&gt;{:url =&amp;gt; {:controller =&gt; 'some_controller', :action =&amp;gt;'some_action', :id =&gt; some_id}},{ :class =&gt; 'some_class' }-%&amp;gt;&lt;/pre&gt;&lt;br /&gt;If you want to specify a fall back url for href instead of the default # you can put that in the html_options part also.&lt;pre&gt;&amp;lt;%= link_to_remote 'Name',&lt;br /&gt;{:url =&amp;gt; {:controller =&amp;gt; 'some_controller', :action =&amp;gt; 'some_action', :id =&amp;gt; some_id}},&lt;br /&gt;{:class =&amp;gt; 'some_class', :href =&amp;gt; url_for({:controller =&amp;gt; 'some_controller', :action =&amp;gt; 'some_action', :id =&amp;gt; some_id}) }-%&amp;gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-9135292809677306194?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/9135292809677306194/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=9135292809677306194' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/9135292809677306194'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/9135292809677306194'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/05/how-to-pass-class-or-id-to-linktoremote.html' title='How to pass a class or id to link_to_remote'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4578603686680385094</id><published>2007-05-05T20:48:00.000-07:00</published><updated>2007-05-05T21:08:07.248-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='netbeans6'/><title type='text'>NetBeans IDE 6.0 M9 is out</title><content type='html'>I just saw that NetBeans 6 Milestone 9 was released. Go &lt;a href="http://wiki.netbeans.org/wiki/view/NewAndNoteWorthyMilestone9"&gt;here&lt;/a&gt; to see all the changes for M9. There are many new features added for Javascript. You can edit embedded Javascript and CSS inside HTML/JSP. Of course, there are new features for Ruby editing.&lt;br /&gt;&lt;br /&gt;Here is the list of changes for Ruby from the site.&lt;br /&gt;&lt;blockquote&gt;&lt;ul&gt;&lt;br /&gt;&lt;li&gt; Advanced code editing: Code completion, Documentation Popup, Semantic highlighting (such as unused local variable coloring), Parameter Hints, Instant Rename, Goto Declaration, Live Code Templates, Mark Occurrences, Reformatting, Pair Matching, Smart Selection, Surround With &lt;/li&gt;&lt;br /&gt;&lt;li&gt; Project support: Create and run files, run unit tests, run RSpec specifications, jump between files and their testcases, Ruby Gems support, ability to use any version of either JRuby or native Ruby &lt;/li&gt;&lt;br /&gt;&lt;li&gt; Ruby Debugger, including Rails debugging - run/step, breakpoints, local variables, call stack, thread switching, balloon evaluation, etc. Support for native fast debugging. &lt;/li&gt;&lt;br /&gt;&lt;li&gt; Ruby On Rails support: Code Generator wizard, Database Migrations, Rake Targets, Support for generator plugins, Jump between Action and View, RHTML highlighting &lt;/li&gt;&lt;br /&gt;&lt;/ul&gt;&lt;/blockquote&gt;&lt;a href="http://bits.netbeans.org/download/6.0/milestones/latest/"&gt;Download&lt;/a&gt; and try it out for yourself.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4578603686680385094?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4578603686680385094/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4578603686680385094' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4578603686680385094'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4578603686680385094'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/05/netbeans-ide-60-m9-is-out.html' title='NetBeans IDE 6.0 M9 is out'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3745768634800848086</id><published>2007-04-01T01:11:00.000-07:00</published><updated>2007-04-01T15:00:51.095-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><category scheme='http://www.blogger.com/atom/ns#' term='netbeans6'/><title type='text'>NetBeans IDE 6.0 M8 is out</title><content type='html'>I just installed &lt;a href="http://wiki.netbeans.org/wiki/view/MilestoneDownloads"&gt;NetBeans IDE 6.0 M8&lt;/a&gt; and noticed that you can start and stop WEBrick within NetBeans now. Before this release, you would have to kill the java task from the task manager which was a pain. I actually didn't use WEBrick within the ide because of this problem. Instead, I just run it from the command line using the native ruby interpreter instead of jruby.&lt;br /&gt;&lt;br /&gt;Before I was able to use the WEBrick instance started by NetBeans, I need to setup the project to use the jdbc adapter for MySQL. Since I didn't really bother reading much instruction, I encountered quite a few problems.&lt;br /&gt;&lt;br /&gt;Here are the steps I used to get everything working.&lt;br /&gt;&lt;br /&gt;1. Modify environment.rb and add these lines in right before Rails::Initializer:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;if RUBY_PLATFORM =~ /java/&lt;br /&gt;  require 'rubygems'&lt;br /&gt;  RAILS_CONNECTION_ADAPTERS = %w(jdbc)&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;Rails::Initializer.run do |config|&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;2. Modify database.yml to use the jdbc adapter. Of course, instead of test_development, you put your own database name there.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;development:&lt;br /&gt;  adapter: jdbc&lt;br /&gt;  driver: com.mysql.jdbc.Driver&lt;br /&gt;  username: root&lt;br /&gt;  password: password&lt;br /&gt;  url: jdbc:mysql://localhost:3306/test_development&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;3. Download the JDBC driver for MySQL.&lt;br /&gt;&lt;a href="http://dev.mysql.com/downloads/connector/j/5.0.html"&gt;Download Connector/J 5.0&lt;/a&gt;&lt;br /&gt;Unzip or untar the archive and copy mysql-connector-java-5.0.5-bin.jar to your jruby-0.9.8\lib.&lt;br /&gt;&lt;br /&gt;You can find your jruby-0.9.8 directory under&lt;br /&gt;C:\Documents and Settings\&amp;lt;your username&amp;gt;\.netbeans\&lt;br /&gt;&lt;br /&gt;I found this step to be quite important because adding the driver to CLASSPATH did not work for me.&lt;br /&gt;&lt;br /&gt;NetBeans also exposed more rake tasks than before.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3745768634800848086?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3745768634800848086/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3745768634800848086' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3745768634800848086'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3745768634800848086'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/04/netbeans-ide-60-m8-is-out.html' title='NetBeans IDE 6.0 M8 is out'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-7453958333671785819</id><published>2007-03-21T10:40:00.000-07:00</published><updated>2007-03-21T11:16:16.760-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>How to use migration</title><content type='html'>Yavor Ivanov over at &lt;a href="http://rubycorner.net/"&gt;rubycorner.net&lt;/a&gt; started a mini series on Rails migration. So far there is one article and I already learned a few things that I didn't know.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://rubycorner.net/articles/how-to-use-rails-migrations-part-i/"&gt;How to use Rails Migrations - Part I&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I created a table with :created_at column as :null =&gt; false but I didn't define the default value so I was having problem with specifying the datetime in my test fixture.&lt;br /&gt;&lt;br /&gt;I solved that problem by putting this in my test fixture:&lt;br /&gt;&lt;pre&gt;created_at: &lt;%= DateTime.now.strftime('%y-%m-%d %H:%M:%S') %&gt;&lt;/pre&gt;What I really should have done is created the column like this.&lt;br /&gt;&lt;pre&gt;t.column :created_at, :datetime, :default =&gt; Time.now&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7453958333671785819?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7453958333671785819/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7453958333671785819' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7453958333671785819'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7453958333671785819'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/how-to-use-migration.html' title='How to use migration'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2851766151157047334</id><published>2007-03-20T16:20:00.000-07:00</published><updated>2007-03-20T16:24:42.578-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Ruby on Rails Caching</title><content type='html'>Gregg Pollack over at &lt;a href="http://www.railsenvy.com/"&gt;Rails Envy&lt;/a&gt; posted two articles on Ruby on Rails Caching. If you have performance issue, you might want to check them out.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.railsenvy.com/2007/2/28/rails-caching-tutorial"&gt;Ruby on Rails Caching Tutorial - Part 1&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.railsenvy.com/2007/3/20/ruby-on-rails-caching-tutorial-part-2"&gt;Ruby on Rails Caching Tutorial - Part 2&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2851766151157047334?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2851766151157047334/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2851766151157047334' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2851766151157047334'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2851766151157047334'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/ruby-on-rails-caching.html' title='Ruby on Rails Caching'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-8008334154669188272</id><published>2007-03-19T22:23:00.000-07:00</published><updated>2007-03-19T22:26:42.477-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Ruby on Rails screencasts</title><content type='html'>I found this website, &lt;a href="http://railscasts.com/"&gt;Railscasts&lt;/a&gt;, that has free Ruby on Rails screencasts. So far, there are 7 screencasts and they are posted pretty regularly.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-8008334154669188272?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/8008334154669188272/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=8008334154669188272' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8008334154669188272'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8008334154669188272'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/ruby-on-rails-screencasts.html' title='Ruby on Rails screencasts'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-8334357957124247165</id><published>2007-03-16T12:52:00.000-07:00</published><updated>2007-03-16T14:43:33.450-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plugin'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Acts As State Machine plugin</title><content type='html'>I just finished reading Bruce Tate article, &lt;a href="http://www-128.ibm.com/developerworks/java/library/j-cb03137/"&gt;Crossing borders: Extensions in Rails (The anatomy of an acts_as plug-in)&lt;/a&gt;, where he mentioned the acts_as_state_machine plugin for Rails. If you ever have model with known transition paths between different states then this plugin will be a great help to you.&lt;br /&gt;&lt;br /&gt;Here is an article, &lt;a href="http://nubyonrails.com/articles/2006/05/04/the-complete-guide-to-rails-plugins-part-i"&gt;The Complete Guide to Rails Plugins: Part 1&lt;/a&gt;, on &lt;a href="http://nubyonrails.com/"&gt;Nuby on Rails&lt;/a&gt; showing how to install and create Rails plugin.&lt;br /&gt;&lt;br /&gt;And finally, you can go to the acts_as_state_machine plugin's author blog, &lt;a href="http://lunchroom.lunchboxsoftware.com/2006/1/21/acts-as-state-machine"&gt;Acts As State Machine&lt;/a&gt;, to see where to download and how to use the plugin.&lt;br /&gt;&lt;br /&gt;Here is my example of how to use the plugin to keep track of a light fixture with three state (off, low, and high).&lt;br /&gt;&lt;pre&gt;&lt;pre&gt;&lt;br /&gt;# The Migration class for light&lt;br /&gt;class CreateLights &lt; ActiveRecord::Migration&lt;br /&gt; def self.up&lt;br /&gt;   create_table :lights do |t|&lt;br /&gt;  t.column :name, :string&lt;br /&gt;  t.column :status, :string&lt;br /&gt;   end&lt;br /&gt; end&lt;br /&gt;&lt;br /&gt; def self.down&lt;br /&gt;   drop_table :lights&lt;br /&gt; end&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;# The Model for light&lt;br /&gt;&lt;br /&gt;# A simple transition for a light with three states, (off, low, high)&lt;br /&gt;#&lt;br /&gt;#  +---------+ switch  +---------+ switch  +---------+&lt;br /&gt;#  | off     |--------&gt;| low     |--------&gt;| high    |&lt;br /&gt;#  +---------+         +---------+         +---------+&lt;br /&gt;#     ^                                         |&lt;br /&gt;#     |_________________________________________|&lt;br /&gt;#&lt;br /&gt;class Light &lt; ActiveRecord::Base&lt;br /&gt; acts_as_state_machine :initial =&gt; :off, :column =&gt; 'status'&lt;br /&gt;&lt;br /&gt; state :off&lt;br /&gt; state :low&lt;br /&gt; state :high&lt;br /&gt;&lt;br /&gt; event :switch do&lt;br /&gt;   transitions :from =&gt; :off,  :to =&gt; :low&lt;br /&gt;   transitions :from =&gt; :low,  :to =&gt; :high&lt;br /&gt;   transitions :from =&gt; :high, :to =&gt; :off&lt;br /&gt; end&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;-------------------------&lt;br /&gt;Here is a sample run:&lt;br /&gt;&lt;br /&gt;&gt;&gt; l = Light.create&lt;br /&gt;=&gt; ...&lt;br /&gt;&gt;&gt; l.current_state&lt;br /&gt;=&gt; :off&lt;br /&gt;&gt;&gt; l.switch!&lt;br /&gt;=&gt; nil&lt;br /&gt;&gt;&gt; l.current_state&lt;br /&gt;=&gt; :low&lt;br /&gt;&gt;&gt; l.switch!&lt;br /&gt;=&gt; nil&lt;br /&gt;&gt;&gt; l.current_state&lt;br /&gt;=&gt; :high&lt;br /&gt;&gt;&gt; l.switch!&lt;br /&gt;=&gt; nil&lt;br /&gt;&gt;&gt; l.current_state&lt;br /&gt;=&gt; :off&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-8334357957124247165?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/8334357957124247165/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=8334357957124247165' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8334357957124247165'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8334357957124247165'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/acts-as-state-machine-plugin.html' title='Acts As State Machine plugin'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-1973054472180611973</id><published>2007-03-15T00:15:00.000-07:00</published><updated>2007-03-15T00:36:54.545-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Tips for working with Test Fixtures in Rails</title><content type='html'>I have a requirement in my migration script that created_at column can not be null.&lt;br /&gt;&lt;br /&gt;t.column :created_at, :datetime, :null =&gt; false&lt;br /&gt;&lt;br /&gt;This cause the Test Fixtures loading to fail. My first attempt to remedy this problem was like this.&lt;br /&gt;&lt;br /&gt;created_at: &lt;%= DateTime.now %&gt;&lt;br /&gt;&lt;br /&gt;This did not work since the date time format is incorrect. The correct format is year-month-day hour:minute:second.&lt;br /&gt;&lt;br /&gt;So, I changed it to&lt;br /&gt;&lt;br /&gt;created_at: &lt;%= DateTime.now.strftime('%y-%m-%d %H:%M:%S') %&gt;&lt;br /&gt;&lt;br /&gt;and it works.&lt;br /&gt;&lt;br /&gt;I don't know if there is a better way to do this but this works for me. Since I went around looking for the solution, I decided to write it down.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-1973054472180611973?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/1973054472180611973/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=1973054472180611973' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1973054472180611973'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1973054472180611973'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/tips-for-working-with-test-fixtures-in.html' title='Tips for working with Test Fixtures in Rails'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2154926309990957149</id><published>2007-03-14T01:24:00.000-07:00</published><updated>2007-03-14T01:32:40.748-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='info'/><title type='text'>Validate a number is an integer and within a certain range</title><content type='html'>Use validates_numericality_of , and validates_inclusion_of  to check that a number is an integer and within a certain range.&lt;br /&gt;&lt;br /&gt;For example:&lt;br /&gt;&lt;br /&gt;You only want to allow people to enter a number between 21 and 30. Here is how you would do it.&lt;br /&gt;&lt;br /&gt;validates_numericality_of :n, :only_integer =&gt; true, :message =&gt; "can only be whole number."&lt;br /&gt;validates_inclusion_of :n, :in =&gt; 21..30, :message =&gt; "can only be between 21 and 30."&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2154926309990957149?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2154926309990957149/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2154926309990957149' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2154926309990957149'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2154926309990957149'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/validate-number-is-integer-and-within.html' title='Validate a number is an integer and within a certain range'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-7718712031654477470</id><published>2007-03-13T23:32:00.000-07:00</published><updated>2007-03-14T01:04:22.043-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Ruby on Rails Quick Reference</title><content type='html'>I was looking for a way to update my rails application to rails 1.2.3 when I found this guide, &lt;a href="http://blogs.tech-recipes.com/johnny/rails-quick-reference/"&gt;Ruby on Rails Quick Reference.&lt;/a&gt; It has descriptions to many frequently use rails features.&lt;br /&gt;&lt;br /&gt;rake rails:update is how you update your rails application.&lt;br /&gt;&lt;br /&gt;Found a cheat sheet with a great deal of information:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://blog.nanorails.com/pages/rails_1.1_cheat_sheet"&gt;Ruby on Rails 1.1 Reference&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7718712031654477470?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7718712031654477470/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7718712031654477470' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7718712031654477470'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7718712031654477470'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/ruby-on-rails-quick-reference.html' title='Ruby on Rails Quick Reference'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-5075389260951838213</id><published>2007-03-13T01:31:00.000-07:00</published><updated>2007-03-13T03:04:38.734-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='netbeans6'/><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Drop Derby and goes back to MySql</title><content type='html'>After my rant yesterday about Derby not supporting column rename, I checked  &lt;a href="http://jruby-extras.rubyforge.org/ActiveRecord-JDBC/"&gt;ActiveRecord-JDBC&lt;/a&gt; document for Derby and column_rename is not one of the supported feature.&lt;br /&gt;&lt;br /&gt;Here is the list of databases and the level of support taken from the document.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;MySQL - Complete support  &lt;/li&gt;&lt;li&gt;PostgreSQL - Complete support  &lt;/li&gt;&lt;li&gt;Oracle - Complete support  &lt;/li&gt;&lt;li&gt;Microsoft SQL Server - Complete support except for change_column_default  &lt;/li&gt;&lt;li&gt;DB2 - Complete, except for the migrations:  &lt;ul&gt;&lt;li&gt;change_column  &lt;/li&gt;&lt;li&gt;change_column_default  &lt;/li&gt;&lt;li&gt;remove_column  &lt;/li&gt;&lt;li&gt;rename_column  &lt;/li&gt;&lt;li&gt;add_index  &lt;/li&gt;&lt;li&gt;remove_index  &lt;/li&gt;&lt;li&gt;rename_table  &lt;/li&gt;&lt;/ul&gt; &lt;/li&gt;&lt;li&gt;FireBird - Complete, except for change_column_default and rename_column  &lt;/li&gt;&lt;li&gt;Derby - Complete, except for:  &lt;ul&gt;&lt;li&gt;change_column  &lt;/li&gt;&lt;li&gt;change_column_default  &lt;/li&gt;&lt;li&gt;remove_column  &lt;/li&gt;&lt;li&gt;rename_column  &lt;/li&gt;&lt;/ul&gt; &lt;/li&gt;&lt;li&gt;HSQLDB - Complete&lt;/li&gt;&lt;/ul&gt;Since MySql is completely supported, I switch to using MySql as the database back end for development.&lt;br /&gt;&lt;br /&gt;I did notice one little problem with Netbeans today. The "Generate" menu item disappeared from the menu for some reason. I closed and reopened Netbeans but that didn't do anything. Finally, I closed the project, reopen it and the Generate menu item came back. It only happened once. I don't remember what I did to cause the problem though.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-5075389260951838213?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/5075389260951838213/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=5075389260951838213' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5075389260951838213'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5075389260951838213'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/drop-derby-and-goes-back-to-mysql.html' title='Drop Derby and goes back to MySql'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-6145872920264376412</id><published>2007-03-12T00:45:00.000-07:00</published><updated>2007-03-12T01:18:56.090-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='database'/><title type='text'>Derby does not support renaming column</title><content type='html'>-- rename_column(:users, :username, :user_name)&lt;br /&gt;rake aborted!&lt;br /&gt;rename_column is not implemented&lt;br /&gt;&lt;br /&gt;Opps, I hit another snag when trying to rename username to user_name. Apparently, Derby does not allow renaming of column. I wiped out the database and started over but that is not a practical way to do thing going forward. I think my experiment with Derby is coming in an end here. I wonder why Sun is endorsing a database that is missing such fundamental feature. I don't remember using a database that does not support renaming of column. I guess there is a first for everything.&lt;br /&gt;&lt;br /&gt;Now, I regretted that I read, "&lt;a href="http://weblogs.java.net/blog/bleonard/archive/2007/03/if_you_thought_1.html"&gt;If You Thought Rails Development Was Fast Before..."&lt;/a&gt;. I wouldn't have tried Derby without reading that article. It should be renamed to "If You Thought Rails Development Was Fast Before... Here Is How To Slow Yourself Down". I know it is a cheap shot but that article really make me think that I would be more productive using Derby as my development database.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-6145872920264376412?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/6145872920264376412/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=6145872920264376412' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6145872920264376412'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6145872920264376412'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/derby-does-not-support-renaming-column.html' title='Derby does not support renaming column'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3592531471154210093</id><published>2007-03-11T23:39:00.000-07:00</published><updated>2007-03-12T00:38:44.186-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='netbeans6'/><title type='text'>Using Rails migration with Netbeans 6.0 M7</title><content type='html'>I hit a temporary road block while following the steps from this article, &lt;a href="http://weblogs.java.net/blog/bleonard/archive/2007/03/if_you_thought_1.html"&gt;If You Thought Rails Development Was Fast Before...&lt;/a&gt;. I wanted to use migration instead of sql to create the table in the database. After using the generator to create the migration file, I couldn't figure out how to call the db:migrate task in rake. There is no obvious way to call it from Netbeans 6 itself. I look everywhere but I couldn't find anything. I look in jruby-0.9.2 directory and rake is there but there is no bat file to call it. So, I created a bat file to call rake then execute rake db:migrate directly from the command prompt. That did the trick.&lt;br /&gt;&lt;br /&gt;Here is the link to a Derby tutorial on how to create a new database in Derby from Netbeans.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.netbeans.org/kb/50/derby-demo.html"&gt;Derby Tutorial&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3592531471154210093?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3592531471154210093/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3592531471154210093' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3592531471154210093'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3592531471154210093'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/using-rails-migration-with-netbeans-60.html' title='Using Rails migration with Netbeans 6.0 M7'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-7664596631732816203</id><published>2007-03-08T13:50:00.000-08:00</published><updated>2007-03-08T13:56:31.565-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>OpenID and Rails</title><content type='html'>Ruby Inside has a collection of links to discusses and resources on OpenID and Rails. At the bottom, there is a link to Bernie Thompson's screencast and additional OpenId resources.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://leancode.com/openid-for-rails/"&gt;OpenID for Rails&lt;/a&gt; - Bernie Thompson&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.rubyinside.com/7-openid-resources-for-rails-developers-418.html"&gt;8 OpenID Resources for Rails Developers&lt;/a&gt; - Ruby Inside&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7664596631732816203?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7664596631732816203/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7664596631732816203' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7664596631732816203'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7664596631732816203'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/openid-and-rails.html' title='OpenID and Rails'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3780930914043379807</id><published>2007-03-07T18:32:00.000-08:00</published><updated>2007-03-07T18:38:37.879-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Rails' validators</title><content type='html'>Every wonder how to use all those validators (validates_presence_of, validates_uniqueness_of, validates_size_of, validates_acceptance_of, etc..), in Rails? Head over to Juixe TechKnow and read  &lt;a href="http://www.juixe.com/techknow/index.php/2006/07/29/rails-model-validators/"&gt;Rails Model Validators&lt;/a&gt;. The author has simple samples and explanations for those and a few more.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3780930914043379807?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3780930914043379807/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3780930914043379807' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3780930914043379807'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3780930914043379807'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/rails-validators.html' title='Rails&apos; validators'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2560955377306414864</id><published>2007-03-05T21:05:00.000-08:00</published><updated>2007-03-05T21:15:50.000-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>Screencast of Ruby editing features in Netbeans 6</title><content type='html'>Roman Strobl, famous for creating screencasts of Matisse GUI Builder in Netbeans 5.0, is at it again. This time he created two screencasts to demonstrate Ruby and Ruby on Rails features in Netbeans 6.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://blogs.sun.com/roumen/entry/two_demos_jruby_on_rails"&gt;Two Demos: JRuby on Rails and Advanced Ruby Editing in NetBeans&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2560955377306414864?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2560955377306414864/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2560955377306414864' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2560955377306414864'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2560955377306414864'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/screencast-of-ruby-editing-features-in.html' title='Screencast of Ruby editing features in Netbeans 6'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-1125001336203086193</id><published>2007-03-04T01:04:00.000-08:00</published><updated>2007-03-04T01:10:10.956-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Ruby Block</title><content type='html'>If you use Ruby for any thing more than a simple "hello world" program then you probably hit Ruby block and closure. I write a lot of Ruby code to process data files. This is an ideal way to open a text file and process all lines within it.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;File.open("filename", "r") do |file|&lt;br /&gt;   file.each_line do |line|&lt;br /&gt;       # do something with the line&lt;br /&gt;   end&lt;br /&gt;end&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;It automatically close the file when it reached the end of the file.&lt;br /&gt;&lt;br /&gt;If you want to learn more about Ruby block then head over to &lt;a href="http://darwinweb.net/"&gt;Darwinweb&lt;/a&gt; and read &lt;a href="http://darwinweb.net/article/Ruby_Blocks_As_Closures"&gt;Ruby Blocks as Closure&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-1125001336203086193?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/1125001336203086193/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=1125001336203086193' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1125001336203086193'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1125001336203086193'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/ruby-block.html' title='Ruby Block'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3266422553159826140</id><published>2007-03-02T21:26:00.000-08:00</published><updated>2007-03-02T21:44:00.154-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Great tips for .Net developers moving over to Ruby</title><content type='html'>Over at &lt;a href="http://www.softiesonrails.com/"&gt;Softies on Rails&lt;/a&gt;, Jeff Cohen has a great on going series of articles titled, Ruby on Rails for .Net developers. The latest one is on &lt;a href="http://www.softiesonrails.com/2007/3/2/ruby-101-for-net-developers-map-and-collect"&gt;map and collection&lt;/a&gt;. I find them quite interesting and helpful. In his example, he has C# codes and the equivalent Ruby codes for us to have a frame of reference when learning to write code in the Ruby way.&lt;br /&gt;&lt;br /&gt;I am a .Net developer by day and a Ruby adventurer by night. Although, I am trying to use more and more Ruby code in my day job. I am currently using Ruby for all my scripting needs. Before Ruby, I was using Perl and that was an adventure.&lt;br /&gt;&lt;br /&gt;Anyway, if you are a .Net developer and wondering what Ruby is all about then you definitely should check out Softies on Rails.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3266422553159826140?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3266422553159826140/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3266422553159826140' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3266422553159826140'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3266422553159826140'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/great-tips-for-net-developers-moving.html' title='Great tips for .Net developers moving over to Ruby'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3854203204095984941</id><published>2007-03-02T19:05:00.000-08:00</published><updated>2007-03-02T19:14:58.234-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>Netbeans 6 and auto completion</title><content type='html'>I started to use Netbeans for all my ruby programming tasks and the auto completion is wonderful. Before, I had to search around Ruby Doc for various libraries and methods but now I can just type the class name and press ctrl-space to get all the methods info. I do find one problem with the auto completion though. When I am editing a single file and not a ruby project, I don't get any auto completion help beside the basic variables within the file. I do get the syntax highlighting though. Unfortunately, a lot of my ruby scripts are quick and dirty and do not warrant creating a whole project just to write it. Maybe there is a way to activate the auto completion in single file editing mode. Anyway, beside that little problem, everything is working great so far.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3854203204095984941?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3854203204095984941/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3854203204095984941' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3854203204095984941'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3854203204095984941'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/netbeans-6-and-auto-completion.html' title='Netbeans 6 and auto completion'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3427743121513335974</id><published>2007-03-01T23:03:00.000-08:00</published><updated>2007-03-01T23:07:38.716-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Articles about Rails Performance on the web</title><content type='html'>This blog entry, &lt;a href="http://www.juixe.com/techknow/index.php/2007/02/28/rails-performance-link-fest/"&gt;Rails Performance Link Fest&lt;/a&gt;, from &lt;a href="http://www.juixe.com/techknow"&gt;Juixe TechKnow&lt;/a&gt; has a ton of links to various web resources regarding Rail Performances.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3427743121513335974?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3427743121513335974/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3427743121513335974' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3427743121513335974'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3427743121513335974'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/articles-about-rails-performance-on-web.html' title='Articles about Rails Performance on the web'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-5442897038981978976</id><published>2007-03-01T11:30:00.000-08:00</published><updated>2007-03-01T11:52:41.896-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>NetBeans IDE 6.0 M7</title><content type='html'>My eternal search for a Ruby editor led me to NetBeans IDE 6.0 M7. It is still in the earlier stage of development but I find its Ruby supports to be pretty good. It has code completion and syntax highlighting. The code completion part is what I like about it. I can't live without code completion.&lt;br /&gt;&lt;br /&gt;You can get milestone 7 by going to &lt;a href="http://www.netbeans.info/downloads/dev.php"&gt;http://www.netbeans.info/downloads/dev.php&lt;/a&gt; and select Q-Build for Build Type. Then download NetBeans IDE 6.0 m7 build 200702191730.&lt;br /&gt;&lt;br /&gt;Here is a series of screenshot from Tor Norbye's Weblog&lt;br /&gt;&lt;br /&gt;&lt;a href="http://blogs.sun.com/tor/entry/ruby_screenshot_of_the_week"&gt;Ruby Screenshot of the Week&lt;/a&gt;&lt;br /&gt;&lt;a href="http://blogs.sun.com/tor/entry/ruby_screenshot_of_the_week1"&gt;Ruby Screenshot of the Week #2&lt;/a&gt;&lt;br /&gt;&lt;a href="http://blogs.sun.com/tor/entry/ruby_screenshot_of_the_week2"&gt;Ruby Screenshot of the Week #3&lt;/a&gt;&lt;br /&gt;&lt;a href="http://blogs.sun.com/tor/entry/ruby_screenshot_of_the_week3"&gt;Ruby Screenshot of the Week #4&lt;/a&gt;&lt;br /&gt;&lt;a href="http://blogs.sun.com/tor/entry/ruby_screenshot_of_the_week4"&gt;Ruby Screenshot of the Week #5&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-5442897038981978976?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/5442897038981978976/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=5442897038981978976' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5442897038981978976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5442897038981978976'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/03/netbeans-ide-60-m7.html' title='NetBeans IDE 6.0 M7'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-1890075693547197282</id><published>2007-02-28T00:12:00.000-08:00</published><updated>2007-02-28T00:16:25.311-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='deployment'/><title type='text'>Running Mongrel on Windows</title><content type='html'>&lt;a href="http://mongrel.rubyforge.org/docs/win32.html"&gt;Mongrel Win32 HOWTO&lt;/a&gt;, from Mongrel shows how to run &lt;a href="http://mongrel.rubyforge.org/index.html"&gt;Mongrel&lt;/a&gt; on Windows environment.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-1890075693547197282?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/1890075693547197282/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=1890075693547197282' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1890075693547197282'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1890075693547197282'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/running-mongrel-on-windows.html' title='Running Mongrel on Windows'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3582772676453471770</id><published>2007-02-11T12:12:00.000-08:00</published><updated>2007-02-11T12:45:39.342-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plugin'/><title type='text'>GeoKit</title><content type='html'>Andre Lewis from &lt;a href="http://earthcode.com/"&gt;Web 2.0 Technologies&lt;/a&gt; website has published a new plugin for Rails that does geocoding, location fingers, and distance calculation.&lt;br /&gt;&lt;br /&gt;Description from website:&lt;br /&gt;&lt;blockquote&gt;Geokit is a Rails plugin for building location-based apps. It provides geocoding, location finders, and distance calculation in one cohesive package. If you have any tables with latitude/longitude oolumns in your database, or if you every wanted to easily query for "all the stores within a 50 mile radius," then GeoKit is for you.&lt;/blockquote&gt;&lt;a href="http://earthcode.com/blog/2007/02/geokit_map_plugin.html"&gt;&lt;br /&gt;GeoKit: a plugin for location-based Rails apps&lt;/a&gt; - Web 2.0 Technologies&lt;br /&gt;&lt;br /&gt;&lt;a href="http://earthcode.com/blog/2007/02/database_distance_calculations.html"&gt;In-memory and in-database distance calculations&lt;/a&gt; -Web 2.0 Technologies&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3582772676453471770?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3582772676453471770/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3582772676453471770' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3582772676453471770'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3582772676453471770'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/geokit.html' title='GeoKit'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3121631508888017443</id><published>2007-02-11T11:47:00.000-08:00</published><updated>2007-02-09T16:29:03.518-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Use Google's smtp server within your Rails application</title><content type='html'>If you use &lt;a href="http://www.google.com/a"&gt;Google Apps&lt;/a&gt; for your domain and has a need to use Google's smtp server to send out email within your Rails application then head over to &lt;a href="http://depixelate.com/"&gt;Depixelate&lt;/a&gt; to see how.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://depixelate.com/2007/2/2/rails-and-google-apps-integration"&gt;Rails and Google Apps / Gmail Integration&lt;/a&gt; - Depixelate&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3121631508888017443?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3121631508888017443/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3121631508888017443' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3121631508888017443'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3121631508888017443'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/use-googles-smtp-server-within-your.html' title='Use Google&apos;s smtp server within your Rails application'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-6815615484558597576</id><published>2007-02-09T16:19:00.000-08:00</published><updated>2007-02-09T16:16:40.639-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>begin rescue else end</title><content type='html'>&lt;a href="http://weblog.jamisbuck.org/"&gt;Jamis Buck&lt;/a&gt; points out the not open used "else" clause of the begin end block. Apparently, the begin end clause can have an else in there.&lt;br /&gt;&lt;br /&gt;For example:&lt;br /&gt;&lt;br /&gt;begin&lt;br /&gt;# Your normal code block&lt;br /&gt;rescue SomeException&lt;br /&gt;# ... handling exception&lt;br /&gt;else&lt;br /&gt;# This part only run if the main code did not throw&lt;br /&gt;# an exception.&lt;br /&gt;ensure&lt;br /&gt;# The very last thing to be run before the clause exit.&lt;br /&gt;# Code in the ensure clause will always get execute.&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;You can read more about this at Jamis Buck blog entry, &lt;a href="http://weblog.jamisbuck.org/2007/2/8/begin-else"&gt;begin + else&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-6815615484558597576?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/6815615484558597576/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=6815615484558597576' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6815615484558597576'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/6815615484558597576'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/begin-rescue-else-end.html' title='begin rescue else end'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-2208945164930845020</id><published>2007-02-09T16:13:00.000-08:00</published><updated>2007-02-09T16:01:16.624-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tool'/><title type='text'>Ruby compiler for .Net</title><content type='html'>If you are a .Net developer but want to write Ruby code, this might be something you want to take a look. It compiles Ruby code into .Net binary so you can run it like normal .Net program.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.plas.fit.qut.edu.au/Ruby.NET/"&gt;Gardens Point Ruby.NET Compiler&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;From their website:&lt;br /&gt;&lt;p&gt;&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;"We are pleased to announce the release of a new Beta (version 0.6) of the Gardens Point          Ruby.NET compiler. Implementation is not yet complete but we have now implemented the          vast majority of Ruby's builtin classes and modules. We have fixed large numbers of existing          bugs, but many still remain. We have not yet implemented continuations or Ruby threads but          support most other language features.     &lt;/p&gt;     &lt;p&gt;         In addition to passing all 871 tests in the samples/test.rb installation test suite of          Ruby 1.8.2, we are now able to support the standard Ruby test unit library and pass most          of the 1864 assertions in the test/ruby test directory."&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-2208945164930845020?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/2208945164930845020/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=2208945164930845020' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2208945164930845020'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/2208945164930845020'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/ruby-compiler-for-net.html' title='Ruby compiler for .Net'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4853367935438039357</id><published>2007-02-09T15:58:00.000-08:00</published><updated>2007-02-08T15:03:44.900-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Extending ActionController</title><content type='html'>Robby Russel from &lt;a href="http://www.robbyonrails.com/"&gt;Robby on Rails&lt;/a&gt; blog wrote an article on extending the ActionController. Extending the ActionController seems to be quite easy.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.robbyonrails.com/articles/2007/02/09/extending-actioncontroller-part-two"&gt;Extending ActionController&lt;/a&gt; - Roby on Rails&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4853367935438039357?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4853367935438039357/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4853367935438039357' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4853367935438039357'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4853367935438039357'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/extending-actioncontroller.html' title='Extending ActionController'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-5702015503991350205</id><published>2007-02-08T14:56:00.000-08:00</published><updated>2007-02-06T22:20:02.284-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tool'/><title type='text'>Intype code editor</title><content type='html'>For all of those people that want to use &lt;a href="http://macromates.com/"&gt;TextMate&lt;/a&gt; on Windows. This editor might be the answer.&lt;br /&gt;&lt;br /&gt;From Intype's website:&lt;br /&gt;&lt;a href="http://intype.info/home/index.php"&gt;&lt;/a&gt;&lt;blockquote&gt;&lt;a href="http://intype.info/home/index.php"&gt;"Intype&lt;/a&gt; is a powerful and intuitive code editor for Windows with lightning fast response.      It is easily extensible and customizable, thanks in part to its support for scripting and native plug-ins.      It makes development in any programming or scripting language quick and easy."&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-5702015503991350205?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/5702015503991350205/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=5702015503991350205' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5702015503991350205'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/5702015503991350205'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/intype-code-editor.html' title='Intype code editor'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-3229410105272018709</id><published>2007-02-06T22:17:00.000-08:00</published><updated>2007-02-06T22:20:02.391-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='installation'/><title type='text'>If you are having problem with the new RubyGems</title><content type='html'>If you are getting&lt;br /&gt;&lt;pre&gt;&lt;code&gt;ERROR: While executing gem … (NoMethodError) undefined  &lt;br /&gt; method `refresh’ for #&lt;/code&gt;&lt;/pre&gt;lately then here might be a fix to your problem.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://weblog.rubyonrails.com/2007/2/6/in-case-you-re-having-trouble-installing-gems"&gt;In case you're having trouble installing gems&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-3229410105272018709?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/3229410105272018709/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=3229410105272018709' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3229410105272018709'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/3229410105272018709'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/if-you-are-having-problem-with-new.html' title='If you are having problem with the new RubyGems'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-7569401197324966923</id><published>2007-02-05T17:05:00.000-08:00</published><updated>2007-02-05T17:11:15.058-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Using Captchator service in Rails</title><content type='html'>Here is an article, &lt;a href="http://errtheblog.com/post/585"&gt;Captchator on Rails&lt;/a&gt;, from &lt;a href="http://errtheblog.com/"&gt;ERR THE BLOG&lt;/a&gt; on how to use the &lt;a href="http://captchator.com/"&gt;Captchator &lt;/a&gt;web service within your Rails application. If for some reason you can't use a local captcha method or don't want to host your own captcha then this might be a good alternative.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7569401197324966923?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7569401197324966923/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7569401197324966923' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7569401197324966923'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7569401197324966923'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/using-captchator-service-in-rails.html' title='Using Captchator service in Rails'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-8292146963677108310</id><published>2007-02-05T16:41:00.000-08:00</published><updated>2007-02-05T16:48:30.987-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plugin'/><title type='text'>Paging in Rails</title><content type='html'>The author of &lt;a href="http://errtheblog.com/"&gt;ERR THE BLOG&lt;/a&gt; finds paging in Rails not up to his standard so he wrote his own paging code. He packed it up as a plugin and now we all can enjoy the fruit of his labor. There are some interesting comments to his blog entry that you might want to take a look.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://errtheblog.com/post/929"&gt;I Will Paginate&lt;/a&gt; - ERR THE BLOG&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-8292146963677108310?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/8292146963677108310/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=8292146963677108310' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8292146963677108310'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8292146963677108310'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/paging-in-rails.html' title='Paging in Rails'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-8210665101119776188</id><published>2007-02-04T09:54:00.000-08:00</published><updated>2007-02-05T15:42:35.934-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plugin'/><title type='text'>Hpricot - HTML Parser for Ruby</title><content type='html'>&lt;a href="http://code.whytheluckystiff.net/hpricot/"&gt;Hpricot&lt;/a&gt; - HTML Parser for Ruby&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-8210665101119776188?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/8210665101119776188/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=8210665101119776188' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8210665101119776188'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8210665101119776188'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/hpricot-html-parser-for-ruby.html' title='Hpricot - HTML Parser for Ruby'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-7783250427957695460</id><published>2007-02-04T09:34:00.000-08:00</published><updated>2007-02-04T10:01:23.940-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plugin'/><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Active Merchant</title><content type='html'>&lt;a href="http://home.leetsoft.com/am"&gt; Active Merchant&lt;/a&gt; is a payment library extracted from &lt;a href="http://shopify.com/"&gt;Shopify&lt;/a&gt;. Here is an article, &lt;a href="http://www.omninerd.com/2007/01/23/articles/66"&gt;Processing Credit Cards with Ruby on Rails&lt;/a&gt;, on how to use it with Authorize.net payment gateway from &lt;a href="http://www.omninerd.com/"&gt;OmniNerd&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;The list of supported payment gateways from Active Merchant website.&lt;br /&gt;&lt;p&gt;Direct payment gateways:    &lt;/p&gt; &lt;ul&gt;&lt;li&gt;Authorize.net &lt;/li&gt;&lt;li&gt;&lt;a class="ext-link" href="http://www.moneris.com/"&gt;&lt;span class="icon"&gt;Moneris&lt;/span&gt;&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a class="ext-link" href="http://www.trustcommerce.com/"&gt;&lt;span class="icon"&gt;TrustCommerce&lt;/span&gt;&lt;/a&gt; &lt;/li&gt;&lt;li&gt;LinkPoint &lt;/li&gt;&lt;li&gt;Psigate &lt;/li&gt;&lt;li&gt;Paypal Payments Pro &lt;/li&gt;&lt;li&gt;Eway &lt;/li&gt;&lt;li&gt;USA ePay &lt;/li&gt;&lt;li&gt;Paypal Payflow Pro (Testing) &lt;/li&gt;&lt;/ul&gt;&lt;p&gt; Offsite payment gateways:  &lt;/p&gt; &lt;ul&gt;&lt;li&gt;Paypal  &lt;/li&gt;&lt;li&gt;Chronopay &lt;/li&gt;&lt;li&gt;Nochex &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-7783250427957695460?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/7783250427957695460/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=7783250427957695460' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7783250427957695460'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/7783250427957695460'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/active-merchant.html' title='Active Merchant'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-8233761132222716151</id><published>2007-02-04T00:01:00.000-08:00</published><updated>2007-02-04T09:56:53.906-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='installation'/><title type='text'>Steps to setup Ruby, Rails, and MySQL on MAC OS X</title><content type='html'>Link to an article with detail instructions for setting up Ruby, Rails, and MySQL on MAC OS X.&lt;br /&gt;&lt;a href="http://hivelogic.com/narrative/articles/ruby-rails-mongrel-mysql-osx"&gt;Building Ruby, Rails, Subversion, Mongrel, and MySQL on Mac OS X&lt;/a&gt; from HIVELOGIC.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-8233761132222716151?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/8233761132222716151/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=8233761132222716151' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8233761132222716151'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8233761132222716151'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/steps-to-setup-ruby-rails-and-mysql-on.html' title='Steps to setup Ruby, Rails, and MySQL on MAC OS X'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4586486169491274632</id><published>2007-02-02T10:02:00.000-08:00</published><updated>2007-02-02T10:07:13.482-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='deployment'/><title type='text'>Rails deployment help</title><content type='html'>If you have problems with deploying your rails application, you might want to go to this Google Group's &lt;a href="http://groups.google.com/group/rubyonrails-deployment"&gt;rails-deployment &lt;/a&gt;for some help.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4586486169491274632?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4586486169491274632/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4586486169491274632' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4586486169491274632'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4586486169491274632'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/rails-deployment-help.html' title='Rails deployment help'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-8260543903967749002</id><published>2007-02-02T09:44:00.000-08:00</published><updated>2007-02-02T10:06:04.016-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='podcast'/><title type='text'>Presentations from San Diego ruby users group</title><content type='html'>&lt;a href="http://podcast.sdruby.com/"&gt;sd.rb podcast&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The San Diego ruby users group posted various videos of presentations at their meetings on ruby.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-8260543903967749002?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/8260543903967749002/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=8260543903967749002' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8260543903967749002'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/8260543903967749002'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/presentations-from-san-diego-ruby-users.html' title='Presentations from San Diego ruby users group'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-4426189376575240924</id><published>2007-02-02T09:20:00.000-08:00</published><updated>2007-02-02T09:49:38.281-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>RadRails 0.7.2</title><content type='html'>&lt;a href="http://www.radrails.org/"&gt;RadRails&lt;/a&gt; is up to version 0.7.2 now.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-4426189376575240924?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/4426189376575240924/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=4426189376575240924' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4426189376575240924'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/4426189376575240924'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/radrails-072.html' title='RadRails 0.7.2'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-1851953883420170600</id><published>2007-02-02T09:04:00.000-08:00</published><updated>2007-02-02T09:49:06.917-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plugin'/><title type='text'>Piston</title><content type='html'>&lt;a href="http://piston.rubyforge.org/usage.html"&gt;Piston&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;If you use svn:externals to manage plugins for your rails application then this utility will definitely make your life easier. It allows you to keep a copy of the plugin in your local repository and also allows you to update it with the external source.&lt;br /&gt;&lt;br /&gt;What is the benefit of having a local copy of the plugin in your repository versus using svn:external? When you do svn update, it will be a lot faster since it doesn't need to go out to external repositories to check for updates.&lt;br /&gt;&lt;br /&gt;When you want to sync the plugin with the external source, all you have to do is type:&lt;br /&gt;&lt;br /&gt;$piston update vendor/rails&lt;br /&gt;&lt;br /&gt;and then&lt;br /&gt;&lt;br /&gt;$svn commit --message "sync up plugins with external source"&lt;br /&gt;&lt;br /&gt;Life couldn't be easier.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-1851953883420170600?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/1851953883420170600/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=1851953883420170600' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1851953883420170600'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/1851953883420170600'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2007/02/piston.html' title='Piston'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-113291198103806671</id><published>2005-11-25T01:45:00.000-08:00</published><updated>2007-02-04T09:56:31.006-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>RadRails 0.5</title><content type='html'>&lt;a href="http://www.radrails.org/"&gt;RadRails 0.5&lt;/a&gt; was released. These guys are working hard even on holiday.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-113291198103806671?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/113291198103806671/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=113291198103806671' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113291198103806671'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113291198103806671'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/11/radrails-05.html' title='RadRails 0.5'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-113291054269697975</id><published>2005-11-25T01:13:00.000-08:00</published><updated>2007-02-04T09:57:09.962-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='installation'/><title type='text'>Step by Step Instruction on Installing Ruby on Rails on Ubuntu 5.04</title><content type='html'>Here is a link to a &lt;a href="http://paulgoscicki.com/archives/2005/09/ruby-on-rails-on-ubuntu/"&gt;step by step instruction&lt;/a&gt; on installing Ruby on Rails on Ubuntu 5.04. I switched my installation from using the Rails version that comes from Ubuntu to the one installed through RubyGems. The reason I did this was to be able to use the latest version of Rails.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-113291054269697975?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/113291054269697975/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=113291054269697975' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113291054269697975'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113291054269697975'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/11/step-by-step-instruction-on-installing.html' title='Step by Step Instruction on Installing Ruby on Rails on Ubuntu 5.04'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-113248022806302693</id><published>2005-11-20T01:45:00.000-08:00</published><updated>2007-02-04T10:00:45.378-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tutorial'/><title type='text'>Links to Ruby on Rails Tutorials</title><content type='html'>Digitial Media Minutes posted &lt;a href="http://www.digitalmediaminute.com/article/1816/top-ruby-on-rails-tutorials"&gt;12 Top Links&lt;/a&gt; to Ruby on Rails tutorials. It is definitely something you should look into if you want to learn about Ruby on Rails. It has tutorials on everything from beginning development to deployment.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-113248022806302693?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/113248022806302693/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=113248022806302693' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113248022806302693'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113248022806302693'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/11/links-to-ruby-on-rails-tutorials.html' title='Links to Ruby on Rails Tutorials'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-113179230297065523</id><published>2005-11-12T02:19:00.000-08:00</published><updated>2007-02-04T09:57:31.051-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='installation'/><title type='text'>Finally managed to get RadRails working on Ubuntu 5.04</title><content type='html'>I finally managed to get RadRails working on my Linux machine. The reason I was having problem connecting to MySQL database was because I didn't turn on networking for MySQL. Yes, I am an idiot but it wasn't obvious that MySQL is skipping networking. It was only using socket and not TCP/IP.&lt;br /&gt;&lt;br /&gt;I forgot the reason why I was doing netstat -a on the machine. But while looking through the list I didn't see any process listening on port 3306. That was odd since I was expecting MySQL to be listening to that port. I took a look at /etc/mysql/my.cnf and sure enough port=3306 is there. So, the next obvious step was googling to see why that is the case. I found &lt;a href="http://www.linuxquestions.org/questions/history/370210"&gt;this post&lt;/a&gt; which talk about skip_networking option in my.cnf. I look at my own my.cnf and skip_networking was enabled. I commented it out and restarted MySQL. I could see a process listening on port 3306 after doing a netstat -a. I tried to telnet to the port but got this error, "localhost.localdomain' is not allowed to connect to this MySQL server Connection closed by foreign host".&lt;br /&gt;&lt;br /&gt;So, I added localhost.localdomain to the list of allowed hosts in MySQL and I was able to telnet to port 3306. I fired up RadRails and attempted to start the server. I still get the database connection error but now there is an error message about todo@localhost.localdomain is not allow. I went ahead and added the user to the database and now everything is working. I can finally use RadRails to start developing the Todo tutorial. I probably has the least secure MySQL server in the world but it is behind the firewall so it shouldn't be a problem.&lt;br /&gt;&lt;br /&gt;Also, &lt;a href="http://www.radrails.org/"&gt;RadRails 0.4.1&lt;/a&gt; is out. I can't wait until I have some free time to spend playing around with &lt;a href="http://www.rubyonrails.com/"&gt;Ruby on Rails&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-113179230297065523?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/113179230297065523/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=113179230297065523' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113179230297065523'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113179230297065523'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/11/finally-managed-to-get-radrails.html' title='Finally managed to get RadRails working on Ubuntu 5.04'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-113083236687422529</id><published>2005-10-31T23:44:00.000-08:00</published><updated>2007-02-04T09:57:49.958-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><title type='text'>RadRails 0.4</title><content type='html'>&lt;a href="http://www.radrails.org/"&gt;RadRails&lt;/a&gt; 0.4 is out.&lt;br /&gt;&lt;br /&gt;I am still having the same database connection problem though. I found this &lt;a href="http://www.intertwingly.net/blog/2005/10/28/First-RadRails-Patch"&gt;post&lt;/a&gt; on Sam Ruby's blog that describes my problem but there is still no solution.&lt;br /&gt;&lt;br /&gt;I also ordered &lt;a href="http://www.pragmaticprogrammer.com/titles/rails/index.html"&gt;Agile Web Development with Rails&lt;/a&gt; and &lt;a href="http://www.pragmaticprogrammer.com/titles/ruby/index.html"&gt;Programming Ruby (2nd. Ed.)&lt;/a&gt; to further my knowledge on Ruby on Rails.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-113083236687422529?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/113083236687422529/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=113083236687422529' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113083236687422529'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/113083236687422529'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/10/radrails-04.html' title='RadRails 0.4'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-112992317888244485</id><published>2005-10-21T12:17:00.000-07:00</published><updated>2007-02-04T09:58:06.666-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ide'/><category scheme='http://www.blogger.com/atom/ns#' term='installation'/><title type='text'>Setting up Rails in Eclipse</title><content type='html'>It has been a while since my last post. I tried to use http://www.radrails.org/ with Eclipse but there seems to be a problem with connecting to the database. I think it has something to do with the new password encryption scheme that MySQL uses. Every time I try to start the web server, it complains about not being able to connect to the database. But the web site actually work and I can get data back from the database. I also not able to create scaffolding since it can't connect to the database. I haven't look deeply to see what is the real reason for the failure yet.&lt;br /&gt;&lt;br /&gt;I also found this website that has instructions on how to setup Rails for Eclipse on Windows. I don't see a reason why these instruction wouldn't work in a Linux environment with some minor changes.&lt;br /&gt;&lt;br /&gt;http://www.napcs.com/howto/railsonwindows.html&lt;br /&gt;&lt;br /&gt;Hopefully, I will find sometime to give these instructions a try.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-112992317888244485?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/112992317888244485/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=112992317888244485' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/112992317888244485'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/112992317888244485'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/10/setting-up-rails-in-eclipse.html' title='Setting up Rails in Eclipse'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-16576374.post-112634870731423825</id><published>2005-09-10T03:32:00.000-07:00</published><updated>2007-02-04T09:58:20.934-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='installation'/><title type='text'>Installing Ruby on Rails</title><content type='html'>The first step in the learning process is actually installing Ruby on Rails into my computer. I have a Dell Inspiron 5000 with Ubuntu 5.04. Installing rails is as simple as adding hoary-backports repository to /etc/apt/sources.list and do an apt-get update and apt-get install rails.&lt;br /&gt;&lt;br /&gt;Here is the &lt;a href="http://wiki.rubyonrails.com/rails/show/RailsOnUbuntuDebianTestingAndUnstable"&gt;installation instructions&lt;/a&gt; for Ruby on Rails on Ubuntu.&lt;br /&gt;&lt;code&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/16576374-112634870731423825?l=learningrubyonrails.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://learningrubyonrails.blogspot.com/feeds/112634870731423825/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=16576374&amp;postID=112634870731423825' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/112634870731423825'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/16576374/posts/default/112634870731423825'/><link rel='alternate' type='text/html' href='http://learningrubyonrails.blogspot.com/2005/09/installing-ruby-on-rails.html' title='Installing Ruby on Rails'/><author><name>Conrad</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
