Archive for May, 2007

Installing the Rails development stack on OS X

I’ve got a bash script I put together a while back for installing the entire Ruby on Rails development stack on an intel based Mac*. I just made some updates that fully automate the process (including selection of platform specific gems).

The nice part is you get prompted for which components you want to install:

<pre> $ sudo ./rails-dev-stack-x86.sh Checking for X11... OK Checking for GCC... OK Install Ruby? y Install Ruby on Rails? y Install Mongrel? y Install FastCGI?n Install Lighttpd w. OpenSSL?n Install ImageMagick and RMagick? y Install Subversion? y Install SQLite? n Install MySQL? y Append paths to .bash_profile? y Go take a break. This is going to take a while... </pre>

Naturally, it’s largely based on the Dan Benjamin’s Guide as well as a few others noted in the script’s preamble. I use it on every machine I need to get setup on, so I try to keep it updated. I’ve been using it for a couple months now, and I thought it was time to share.

  • I think the only processor specific bit might be MySQL installation.

reCAPTCHA for Rails

reCAPTCHA is a new, free, webservice for generating and verifying captcha challenges with some collateral benefits. Last night I dished out some Rails helpers for it. I’ve even gotten a patch in to add some features I hadn’t implemented yet.

  • RDOC at http://ambethia.com/recaptcha
  • Plugin at http://svn.ambethia.com/pub/rails/plugins/recaptcha

It’s pretty straight forward to get up and running, checkout the README.

Tourist Plugin for Rails

I recently joined a team working on an application consisting of no less than 75 models and 22 controllers. Needless to say, finding my way around can be pretty daunting at times. So on a plane to RailsConf I created a plugin to, at the very least, help me debug view templates.

With Tourist installed, you’ll start seeing comments like this wrapped around templates in your rendered HTML:


<!-- BEGIN script/../config/../app/views/narwhal/index.rhtml {{{ -->
<p>...</p>
<!-- END script/../config/../app/views/narwhal/index.rhtml }}} -->