weblog.rubyonrails.org

jQuery as new default Javascript library, streaming response support, attr_accessible with roles, prepared statements, easier migrations.

If you have a time given in a different time zone than your local one, parsing will convert it for...

I believe that when WEBrick has trouble bringing up your Rails application, the WEBrick component that is supposed to print...

If you have any class which requires access to some path methods generated by your routes. Even though you could...

While it might seem trivial to implement an invoice that sums up items and shows net, gross and vat totals...

You've been there: A form cannot be submitted, but you don't see a validation error because the field...

Calling Time#utc, Time#gmt or Time#localtime will not create a converted copy. Instead these methods modify the receiving...

After updating Rubygems you see a wall of deprecation warnings like this: NOTE: Gem::SourceIndex#add_spec is deprecated, use...

I recently browsed through the ActiveSupport code and found some nice stuff I did not know about: ActiveSupport::Callbacks

Consider this HTML: Even though the surrounding container defines a line-height, which vertically centers its inline elements, the check...

When the Ruby parser module of Ruby-GetText comes across a file in one of its search directories (e.g. lib/scripts...

If you want to use the (badly implemented!) solarized color scheme in your Rubymine IDE: Clone the IntelliJ IDEA port...

If you use Amazon AWS cloud services you definitively want to utilize software raid for IO intensive stuff such as...

Date::Performance is a gem that replaces various method in Ruby's Date class with fast C implementations. Unfortunately it...

Attached is a working config to deploy an application with Capistrano that needs to monitor Resque workers with God.

Hint: There's another card with this helper for Cucumber features. Sometimes you feel like you need to stub some...

The Capybara API is somewhat hard for parse for a list of methods you can call on a Capybara node...

When your Cucumber feature needs to browse the page HTML, and you are not sure how to express your query...

When you need to create a locale for a language variant (like Austrian for German), you probably don't want...

github.com

When you need to use diff in either some Ruby code or your Rails app, use the differ gem.

robots.thoughtbot.com

I think this pattern is really useful not just for upgrading suites from Webrat, but really anywhere you have an...

makandra dev
web.archive.org

When you need to zip up files in Ruby, use zipruby. sudo gem install zipruby You can add existing files...

To offer files for download, use send_file. def download(file) send_file file.path, :disposition => 'attachment' end

If you're writing a spec for an application using Resque, you may need to work off queues manually without...