Broke down, saw the light, whatever you want to call it, but I finally whipped up my first Rails app last night.

When I first looked at Rails a few months ago, I liked what I saw but was frustrated by the extreme magicalness of the framework which baked a number of assumptions into your app I wasn’t willing to concede. Turns out Rails hit the sweet spot of being good enough, the sweet spot where people pile on and the framework has improved rapidly.

Rails 0.10.1 has the flexibility to let me build my app while still being a rapid development environment, has some decent non-toy apps (like Hieraki) to learn from, and is developing an impressive body of documentation. (made slightly less impressive by the tendency to get transient exceptions while browsing said documentation)

I love the new routing work, as much as I was (and am) skeptical of moving mod_rewrite functionality into Ruby. And fixtures are a dream to work with. If you’re trying to learn the framework try writing some tests, I kid you not, best, easiest, most fun way to start really fleshing out your functionality.

If you’ve been putting off playing with Rails, now wouldn’t be a bad time to start playing.

On Debian (Testing)

The only piece that wasn’t fun was getting it working on Debian. There is an unstable Rails package, but on testing you’ll need to go and collect each of the dozen+ dependencies.

The following code snippet was suggested, but I haven’t tried it:

apt-get install $(grep-available -n -s package -F source -X ruby1.8 | grep lib)

Errno::ENOENT (No such file or directory – /tmp/mysql.sock)

Had to update my database.yml to point to 127.0.0.1 instead of localhost (thanks lattice)

BlueCloth

Loading BlueCloth as a gem was failing quietly, and the only error I was seeing was

NameError: uninitialized constant BlueCloth

Finally copied bluecloth.rb to site_ruby and loaded it via require instead of require_gem, and found out that I had missed yet another key ruby package libstrscan-ruby

My First App

I’m not sure the world needs another online recipe repository, especially another crappy one, but I’ve never liked any of the ones I’ve played with, and as we’ve been having more dinner parties lately it was time to finally start jotting down some recipes. (and rabble, a recipe is not a todo list)

I’ve built it with tagging support (because I’m like that), and pingback support so that I can keep a cooking journal in Wordpress and have the links automatically get added to the recipe.

I did not build a natural language parser ala Recipezaar, there is no print recipe card mode, and Eatdrinkfeelgood support is only a fond fantasy.

A link will follow once I’ve done the migration from WEBrick to lighthttpd/fcgi.