Jun 12 Rails 2.3.2: checking your deployment works

tags: rails 2.3.2 deploy | comments

For some hours I have being struggling to make my fresh Rails 2.3.2 app go up on passenger. Everything was OK, you know fully BDD-ed, capistranized, but still no logs, no hoptoad, nothing was showing nothing about that annoying 500 error.

read more »

May 11 prawn + prawnto: easy ruby PDF generation, but a Rails 2.1 gotcha

tags: pdf prawn prawnto rails 2.1.0 gotcha | comments

Prawn is the new crack to generate pdfs in ruby. Its Rails add-on prawnto make Rails reports and documents generation a charm. But still there’s a little gotcha that can stop you from using it in your Rails 2.1.0 app out of the box. read more »

Apr 24 fetching Google Calendar events in Ruby

tags: rexml google data api google calendar | comments

You have a Google Calendar and you want to make some cool things by fetching your events, the Google Calendar API and the gdata ruby gem make that a charm. It’s all about login in to your calendar, fetching the events and parsing the REXML response.

read more »

Apr 24 Warden: a Rack middleware for authentication across all apps

tags: rack authentication | comments

Daniel Neighman (hassox) of MerbAuth fame have been working to port over MerbAuth authentication framework to a generalized authentication rack middleware. This is done specifically with the idea of mountable applications in mind, and is constructed in such a way that authentication can be available across all downstream applications in the rack graph.

read more »

Apr 17 Insoshi tests that use Ultrasphinx

tags: ultrasphinx test | comments

Ultrasphinx is a configurator and client to the Sphinx full text search engine by Evan Weaver. Insoshi uses it, but be aware that you need to generate your Ultrasphinx configurations so your tests run and no strange errors occur: read more »

Apr 17 Emacs cucumber mode

tags: emacs cucumber | comments

Michael Klishin have deviced a cucumber-mode.el mode for Emacs that provides all the sweet syntax hightlights and yasnippets snippets. You clone it or download it, throw it in your elisp/ directory and then adding this to your .emacs you’ll get all the goodies:

read more »

Apr 16 Cucumber step negating another expectation step

tags: cucumber step | comments

Cucumber is in the opinion of many a kick ass project, and no wonder given all it provides. I’ve being using it in several projects with great joy. Sometimes you need an expectation step to exactly negate another expectation step, generally is not clear what’s the meaning of negate an expectation step, but in boolean expectations it is easy to not them.

read more »

Apr 14 Sorting arrays of any object in Ruby

tags: arrays sorting | comments

Today I needed in my test units to assert whether arrays of Active Records objects were equal or not. That requires me to sort the arrays, since order is important when checking for equality of arrays.

read more »

Mar 24 geokit gem: getting country from Google reverse geocoding

tags: geokit geocoding gem | comments

geokit ruby gem provides geocoding and distance/heading calculations. Paired with the geokit-rails plugin you get a full-fledged location-based app with lot’s of goodies for geolocation, ip geolocation, reverse geocoding, distance calculations between models and more. read more »

Mar 23 debian: installed packages

tags: debian packages | comments

Listing installed packages in debian is easy, you list them with dpkg and then grep them:

$ dpkg --get-selections | grep git
git-core        install
git-svn          install
gitk              install
read more »