<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/wordpress-mu-1.2.4" -->
<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/"
	>

<channel>
	<title>Dmitry Vanidovsky's blog</title>
	<link>http://vanidovsky.blog.net.ua</link>
	<description>Just another Ruby on Rails weblog</description>
	<pubDate>Wed, 31 Oct 2007 15:30:34 +0000</pubDate>
	<generator>http://wordpress.org/?v=wordpress-mu-1.2.4</generator>
	<language>en</language>
			<item>
		<title>rspec navigation using rails.vim</title>
		<link>http://vanidovsky.blog.net.ua/2007/10/31/rspec-navigation-using-railsvim/</link>
		<comments>http://vanidovsky.blog.net.ua/2007/10/31/rspec-navigation-using-railsvim/#comments</comments>
		<pubDate>Wed, 31 Oct 2007 13:37:01 +0000</pubDate>
		<dc:creator>mitjok</dc:creator>
		
		<category><![CDATA[rspec]]></category>

		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://vanidovsky.blog.net.ua/2007/10/31/rspec-navigation-using-railsvim/</guid>
		<description><![CDATA[Tim Pope hinted about adding custom Rcommands to supports navigation in rspec files with rails.vim plugin Something like :Rspecmodel, :Rspeccontroller, :Rspecview, :Rspechelper. Just add the following code in your .vimrc:
" RSpec navigation commands
autocmd User Rails Rcommand specmodel spec/models -glob=**/*
\-suffix=_spec.rb -default=model()
autocmd User Rails Rcommand spechelper spec/helpers -glob=**/*
\-suffix=_helper_spec.rb -default=controller()
autocmd User Rails Rcommand speccontroller spec/controllers -glob=**/*
\-suffix=_controller_spec.rb -default=controller()
autocmd User [...]]]></description>
			<content:encoded><![CDATA[<p>Tim Pope hinted about adding custom Rcommands to supports navigation in rspec files with <a href="http://svn.tpope.net/rails/vim/railsvim/" rel="external nofollow">rails.vim plugin</a> Something like :Rspecmodel, :Rspeccontroller, :Rspecview, :Rspechelper. Just add the following code in your .vimrc:</p>
<pre><code>" RSpec navigation commands
autocmd User Rails Rcommand specmodel spec/models -glob=**/*
\-suffix=_spec.rb -default=model()
autocmd User Rails Rcommand spechelper spec/helpers -glob=**/*
\-suffix=_helper_spec.rb -default=controller()
autocmd User Rails Rcommand speccontroller spec/controllers -glob=**/*
\-suffix=_controller_spec.rb -default=controller()
autocmd User Rails Rcommand specview spec/views -glob=**/*
\-suffix=_view_spec.rb
</code></pre>
<p>You may customize :Rspecview command to match &#8216;html.erb&#8217; suffix.  And of course, :RSmodel, :RScontroller, etc. opens specs in split window.<br />
See *rails-custom-navigation* and *rails-rspec* in <a href="http://svn.tpope.net/rails/vim/railsvim/doc/rails.txt" rel="external nofollow">docs</a></p>
]]></content:encoded>
			<wfw:commentRss>http://vanidovsky.blog.net.ua/2007/10/31/rspec-navigation-using-railsvim/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Valuable addition to vim ruby/rails plugins</title>
		<link>http://vanidovsky.blog.net.ua/2007/10/25/valuable-addition-to-vim-rubyrails-plugins/</link>
		<comments>http://vanidovsky.blog.net.ua/2007/10/25/valuable-addition-to-vim-rubyrails-plugins/#comments</comments>
		<pubDate>Thu, 25 Oct 2007 11:02:42 +0000</pubDate>
		<dc:creator>mitjok</dc:creator>
		
		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://vanidovsky.blog.net.ua/2007/10/25/valuable-addition-to-vim-rubyrails-plugins/</guid>
		<description><![CDATA[snippetsEmu : An attempt to emulate TextMate&#8217;s snippet expansion
Here&#8217;s some of them which related to rails migrations:

 mct create_table
 mcdt create_table
 mrnt rename_table
 mdt drop_table
 mcc t.column
 mac add_column
 marc add_column
 mrnc rename_column
 mrc remove_column

see also Rails Migration Cheat Sheet, section Snippets for more info
]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.vim.org/scripts/script.php?script_id=1318" rel="external nofollow">snippetsEmu : An attempt to emulate TextMate&#8217;s snippet expansion</a></p>
<p>Here&#8217;s some of them which related to rails migrations:</p>
<ul>
<li> mct create_table</li>
<li> mcdt create_table</li>
<li> mrnt rename_table</li>
<li> mdt drop_table</li>
<li> mcc t.column</li>
<li> mac add_column</li>
<li> marc add_column</li>
<li> mrnc rename_column</li>
<li> mrc remove_column</li>
</ul>
<p>see also <a href="http://garrettsnider.backpackit.com/pub/367902" rel="external nofollow">Rails Migration Cheat Sheet</a>, section Snippets for more info</p>
]]></content:encoded>
			<wfw:commentRss>http://vanidovsky.blog.net.ua/2007/10/25/valuable-addition-to-vim-rubyrails-plugins/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Ruby method access levels: protected and private</title>
		<link>http://vanidovsky.blog.net.ua/2007/09/27/ruby-method-access-levels-protected-and-private/</link>
		<comments>http://vanidovsky.blog.net.ua/2007/09/27/ruby-method-access-levels-protected-and-private/#comments</comments>
		<pubDate>Thu, 27 Sep 2007 15:58:43 +0000</pubDate>
		<dc:creator>mitjok</dc:creator>
		
		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://vanidovsky.blog.net.ua/2007/09/27/ruby-method-access-levels-protected-and-private/</guid>
		<description><![CDATA[Good example which illustrate the difference between protected and private methods in Ruby:
• Protected methods can be invoked only by objects of the defining class and its subclasses. Access is kept within the family.
• Private methods cannot be called with an explicit receiver—the receiver is always self. This means that private methods can be called [...]]]></description>
			<content:encoded><![CDATA[<p>Good <a href="http://redsquirrel.com/cgi-bin/dave/dynamic/ruby.protected.access.html" rel="external nofollow">example </a>which illustrate the difference between protected and private methods in Ruby:</p>
<blockquote><p>• Protected methods can be invoked only by objects of the defining class and its subclasses. Access is kept within the family.<br />
• Private methods cannot be called with an explicit receiver—the receiver is always <em><strong>self</strong></em>. This means that private methods can be called only in the context of the current object; you can’t invoke another object’s private methods. (c) PickAxe.</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://vanidovsky.blog.net.ua/2007/09/27/ruby-method-access-levels-protected-and-private/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Adding custom hash methods to Edge Rails</title>
		<link>http://vanidovsky.blog.net.ua/2007/03/02/adding-custom-hash-methods-to-edge-rails/</link>
		<comments>http://vanidovsky.blog.net.ua/2007/03/02/adding-custom-hash-methods-to-edge-rails/#comments</comments>
		<pubDate>Fri, 02 Mar 2007 16:37:17 +0000</pubDate>
		<dc:creator>mitjok</dc:creator>
		
		<category><![CDATA[hash]]></category>

		<guid isPermaLink="false">http://vanidovsky.blog.net.ua/2007/03/02/adding-custom-hash-methods-to-edge-rails/</guid>
		<description><![CDATA[1. Read this
2. cd vendor/rails/activesupport/lib/active_support/core_ext/hash
3. make file filter.rb and add functions to the module Filter, as example use other files in this directory
4. make necessary changes in hash.rb in vendor/rails/activesupport/lib/active_support/core_ext
]]></description>
			<content:encoded><![CDATA[<p align="left">1. Read <a href="http://blog.unquiet.net/archives/2006/04/13/hash-goodness-or-nice-methods-for-working-with-hashes-in-ruby-rails/">this</a><br />
2. cd vendor/rails/activesupport/lib/active_support/core_ext/hash<br />
3. make file filter.rb and add functions to the module Filter, as example use other files in this directory<br />
4. make necessary changes in hash.rb in vendor/rails/activesupport/lib/active_support/core_ext</p>
]]></content:encoded>
			<wfw:commentRss>http://vanidovsky.blog.net.ua/2007/03/02/adding-custom-hash-methods-to-edge-rails/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Easy fixtures creation/extraction</title>
		<link>http://vanidovsky.blog.net.ua/2007/02/23/fixtures/</link>
		<comments>http://vanidovsky.blog.net.ua/2007/02/23/fixtures/#comments</comments>
		<pubDate>Fri, 23 Feb 2007 12:25:45 +0000</pubDate>
		<dc:creator>mitjok</dc:creator>
		
		<category><![CDATA[fixtures]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Need fixtures to be used in tests? And it should be real data which will be used in you application in future?
1. Feed your database with data using scaffolding forms. 
2. Extract them with rake task into your .yml file.
3. To make them convert correctly to UTF-8 use Ya2YAML instead to_yaml in above rake task.
]]></description>
			<content:encoded><![CDATA[<p>Need fixtures to be used in tests? And it should be real data which will be used in you application in future?</p>
<p>1. Feed your database with data using scaffolding forms. <br />
2. <a href="http://snippets.dzone.com/tag/fixtures" title="Create YAML test fixtures from data in an existing database">Extract</a> them with rake task into your .yml file.<br />
3. To make them convert correctly to UTF-8 use <a href="http://rubyforge.org/projects/ya2yaml/">Ya2YAML</a> instead to_yaml in above rake task.</p>
]]></content:encoded>
			<wfw:commentRss>http://vanidovsky.blog.net.ua/2007/02/23/fixtures/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
