<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>WebOnRails &#187; edge_rails</title>
	<atom:link href="http://webonrails.com/category/edge_rails/feed/" rel="self" type="application/rss+xml" />
	<link>http://webonrails.com</link>
	<description>Its all about Ruby On Rails</description>
	<lastBuildDate>Mon, 05 Jul 2010 16:37:57 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=abc</generator>
		<item>
		<title>Edge Rails: Time#current</title>
		<link>http://webonrails.com/2010/07/05/edge-rails-timecurrent/</link>
		<comments>http://webonrails.com/2010/07/05/edge-rails-timecurrent/#comments</comments>
		<pubDate>Mon, 05 Jul 2010 16:37:57 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[ROR]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[edge rails]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=415</guid>
		<description><![CDATA[Returns Time.zone.now when config.time_zone is set, otherwise just returns Time.now]]></description>
			<content:encoded><![CDATA[<p>Returns <strong>Time.zone.now</strong> when config.time_zone is set, otherwise just returns <strong>Time.now</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2010/07/05/edge-rails-timecurrent/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Edge Rails: Array#random_element</title>
		<link>http://webonrails.com/2010/05/24/edge-rails-arrayrandom_element/</link>
		<comments>http://webonrails.com/2010/05/24/edge-rails-arrayrandom_element/#comments</comments>
		<pubDate>Mon, 24 May 2010 12:30:45 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[ROR]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[Array]]></category>
		<category><![CDATA[edge rails]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=400</guid>
		<description><![CDATA[Array#rand is deprecated in favor of Array#random_element and will be removed in Rails 3. As per the comment added to the commit: Array#rand is deprecated because it masks Kernel#rand within the Array class itself, which may be used by a 3rd party library extending Array in turn. See https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/4555]]></description>
			<content:encoded><![CDATA[<p><strong>Array#rand</strong> is deprecated in favor of <strong>Array#random_element</strong> and will be removed in Rails 3.</p>
<p>As per the comment added to the commit:<br />
<strong>Array#rand</strong> is deprecated because it masks <strong>Kernel#rand</strong> within the Array class itself, which may be used by a 3rd party library extending Array in turn. See  <a href="https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/4555">https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/4555</a></p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2010/05/24/edge-rails-arrayrandom_element/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Edge Rails Updates</title>
		<link>http://webonrails.com/2010/05/14/edge-rails-updates/</link>
		<comments>http://webonrails.com/2010/05/14/edge-rails-updates/#comments</comments>
		<pubDate>Fri, 14 May 2010 15:54:57 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[ROR]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[edge rails]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=391</guid>
		<description><![CDATA[New edge rails deprecations: Time#last_year is deprecated in favor of Time#prev_year Time#last_month is deprecated in favor of Time#prev_month Date#last_year is deprecated in favor of Date#prev_year Date#last_month is deprecated in favor of Date#prev_month New methods/aliases: Date#sunday: Returns a new Date representing the end of this week Time#sunday: Returns a new Time representing the end of this]]></description>
			<content:encoded><![CDATA[<p><strong>New edge rails deprecations:</strong></p>
<p><strong>Time#last_year</strong> is deprecated in favor of <strong>Time#prev_year</strong><br />
<strong>Time#last_month</strong> is deprecated in favor of <strong>Time#prev_month</strong></p>
<p><strong>Date#last_year</strong> is deprecated in favor of <strong>Date#prev_year</strong><br />
<strong>Date#last_month</strong> is deprecated in favor of <strong>Date#prev_month</strong></p>
<p><strong>New methods/aliases:</strong></p>
<p><strong>Date#sunday:</strong> Returns a new Date representing the end of this week<br />
<strong>Time#sunday:</strong> Returns a new Time representing the end of this week<br />
<strong>rename_index:</strong> Rename database index<br />
Ex: rename_index :people, &#8216;index_people_on_last_name&#8217;, &#8216;index_users_on_last_name&#8217;</p>
<p>Feel free to add more as comments..</p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2010/05/14/edge-rails-updates/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Edge rails: ActiveRecord::Base.each and ActiveRecord::Base.find_in_batches for  batch processing</title>
		<link>http://webonrails.com/2009/02/23/edge-rails-activerecordbaseeach-and-activerecordbasefind_in_batches-for-batch-processing/</link>
		<comments>http://webonrails.com/2009/02/23/edge-rails-activerecordbaseeach-and-activerecordbasefind_in_batches-for-batch-processing/#comments</comments>
		<pubDate>Mon, 23 Feb 2009 15:45:25 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[ROR]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[tricks]]></category>
		<category><![CDATA[edge rails]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=251</guid>
		<description><![CDATA[You guys must faced a situation when you need to process large number of records, for example sending newsletters. Then you must have done some sort of batch processing to save it eating up all of your memory. This feature is committed to rails core by DHH. Now you can do something like User.each and]]></description>
			<content:encoded><![CDATA[<p>You guys must faced a situation when you need to process large number of records, for example sending newsletters. Then you must have done some sort of batch processing to save it eating up all of your memory. This feature is committed to rails core by DHH.</p>
<p>Now you can do something like <strong>User.each</strong> and <strong>User.find_in_batches</strong>.</p>
<p>Please refer <a href="http://github.com/rails/rails/blob/45787bdd0e9ec20b111e570a20b5f66a949b400c/activerecord/lib/active_record/batches.rb">here</a> for more details.</p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2009/02/23/edge-rails-activerecordbaseeach-and-activerecordbasefind_in_batches-for-batch-processing/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Generating association while generating model</title>
		<link>http://webonrails.com/2008/12/14/generating-association-while-generating-model/</link>
		<comments>http://webonrails.com/2008/12/14/generating-association-while-generating-model/#comments</comments>
		<pubDate>Sun, 14 Dec 2008 11:10:32 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[active_record]]></category>
		<category><![CDATA[associations]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[migration]]></category>
		<category><![CDATA[model]]></category>
		<category><![CDATA[tricks]]></category>
		<category><![CDATA[generator]]></category>
		<category><![CDATA[migrations]]></category>
		<category><![CDATA[ROR]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=172</guid>
		<description><![CDATA[May be you guys are already aware of, but in Rails 2.2 we can specify belongs_to association while generating model. So if we issue: script/generate model Post title:string author:belongs_to We will get a Post model like: class Post &#60; ActiveRecord::Base belongs_to :author end Also it will automatically add the foreign key column in the migration.]]></description>
			<content:encoded><![CDATA[<p>May be you guys are already aware of, but in Rails 2.2 we can specify belongs_to association while generating model. So if we issue:</p>
<pre class="brush: ruby;">
script/generate model Post title:string author:belongs_to
</pre>
<p>We will get a Post model like:</p>
<pre class="brush: ruby;">
class Post &lt; ActiveRecord::Base
  belongs_to :author
end
</pre>
<p>Also it will automatically add the foreign key column in the migration.</p>
<pre class="brush: ruby;">
class CreatePosts &lt; ActiveRecord::Migration
  def self.up
    create_table :posts do |t|
      t.string :title
      t.belongs_to :author

      t.timestamps
    end
  end

  def self.down
    drop_table :posts
  end
end
</pre>
<p>Nothing much but saves some keystrokes. <img src='http://webonrails.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2008/12/14/generating-association-while-generating-model/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Ever tried Rails.root</title>
		<link>http://webonrails.com/2008/12/01/ever-tried-railsroot/</link>
		<comments>http://webonrails.com/2008/12/01/ever-tried-railsroot/#comments</comments>
		<pubDate>Mon, 01 Dec 2008 08:30:56 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[ROR]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[tricks]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=140</guid>
		<description><![CDATA[Guys, have you ever tried Rails.root. It gives same value as RAILS_ROOT. But now in edge rails it is modified and you can do much more with it. You can use Rails.root at places like: File.join(RAILS_ROOT, 'public', 'images') as Rails.root.join('public', 'images') Both gives the same result. Enjoy&#8230;]]></description>
			<content:encoded><![CDATA[<p>Guys, have you ever tried Rails.root. It gives same value as RAILS_ROOT. But now in edge rails it is modified and you can do much more with it.</p>
<p>You can use Rails.root at places like:</p>
<pre class="brush: ruby;">
 File.join(RAILS_ROOT, 'public', 'images')
</pre>
<p>as</p>
<pre class="brush: ruby;">
 Rails.root.join('public', 'images')
</pre>
<p>Both gives the same result.</p>
<p>Enjoy&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2008/12/01/ever-tried-railsroot/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Edge Rails: Now define your plugin&#8217;s routes in plugin&#8217;s config/routes.rb</title>
		<link>http://webonrails.com/2008/11/28/edge-rails-now-define-you-plugins-routes-in-plugins-configroutesrb/</link>
		<comments>http://webonrails.com/2008/11/28/edge-rails-now-define-you-plugins-routes-in-plugins-configroutesrb/#comments</comments>
		<pubDate>Fri, 28 Nov 2008 05:19:26 +0000</pubDate>
		<dc:creator>Akhil Bansal</dc:creator>
				<category><![CDATA[ROR]]></category>
		<category><![CDATA[Rails]]></category>
		<category><![CDATA[Rubyonrails]]></category>
		<category><![CDATA[edge_rails]]></category>
		<category><![CDATA[rails_plugin]]></category>
		<category><![CDATA[routing]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[edge rails]]></category>
		<category><![CDATA[plugin]]></category>

		<guid isPermaLink="false">http://webonrails.com/?p=134</guid>
		<description><![CDATA[If you wrote/writing a rails plugin that need to have an entry in rails routing, you need not to ask your plugin users to make that entry in RAILS_ROOT/config/routes.rb manually any more. In the latest version of rails you can add your custum routes in your plugin config/routes.rb file. Rails will automatically load those routes.]]></description>
			<content:encoded><![CDATA[<p>If you wrote/writing a rails plugin that need to have an entry in rails routing, you need not to ask your plugin users to make that entry in RAILS_ROOT/config/routes.rb manually any more. In the latest version of rails you can add your custum routes in your plugin config/routes.rb file. Rails will automatically load those routes.</p>
]]></content:encoded>
			<wfw:commentRss>http://webonrails.com/2008/11/28/edge-rails-now-define-you-plugins-routes-in-plugins-configroutesrb/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
