Posts Tagged ‘ development ’

Sending email: Controllers versus Models

November 16, 2009
By Robby Russell at Robby on Rails
Sending email: Controllers versus Models

While reviewing some code recently, I came across controller code that resembled the following.if @customer.save CustomerMailer.deliver_welcome_message(@customer) flash = "Your account has been successfully created. We've sent you a welcome letter with..." redirect_to dashboard_path else ... endFairly typical Rails code. Nothing alarming here, but I wanted to evaluate the call to the mailer...
Read more »

Tags: , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Using BETWEEN for SQL comparisons

November 14, 2009
By Robby Russell at Robby on Rails
Using BETWEEN for SQL comparisons

Recently, Carlos, suggested that I should start sharing some basic SQL tips that help with performance and/or general usage. I recently came across some code that I didn’t like to read and/or write. For example, let’s take the following…SELECT * FROM brochures WHERE published_at <= now() AND archived_at >= now()Essentially, this is pulling back...
Read more »

Tags: , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Launching Ruby on Rails projects, the video

November 11, 2009
By Robby Russell at Robby on Rails
Launching Ruby on Rails projects, the video

For those of you who didn’t make it to Rails Underground in July to witness my mind-blowing talk, Launching Ruby on Rails projects , it appears that Skills Matter has finally posted a video of it online. :-)The sound levels are really low… but hopefully you’ll find it helpful.You can also view the slides.Related...
Read more »

Tags: , , , , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Flash Message Conductor now a Gem

October 13, 2009
By Robby Russell at Robby on Rails
Flash Message Conductor now a Gem

We’ve been doing some early (or late… if you’re a half-full kind of person) spring cleaning on some of our projects. One of the small projects, flash_message_conductor, which we released last year as a plugin is now a gem. We’ve been moving away from using plugins in favor of gems as we like locking...
Read more »

Tags: , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Planting the seeds

September 5, 2009
By Robby Russell at Robby on Rails
Planting the seeds

Yesterday, the Rails team released 2.3.4, which includes standardized way for loading seed data into your application so that you didn’t have to clutter your database migrations.I noticed a few comments on some blogs where people were asking how to use this new feature, so here is a quick runthrough a few ways that...
Read more »

Tags: , , , , , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Using model constants for project sanity

June 22, 2009
By Robby Russell at Robby on Rails
Using model constants for project sanity

On one of our larger client projects (approx. 160 models and growing…) we have a specific model that we refer to quite a bit throughout our code. This model contains less than 10 records, but each of them sits on top of an insanely large and complex set of data. Each record refers to...
Read more »

Tags: , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Aliasing resources in Ruby on Rails

June 22, 2009
By Robby Russell at Robby on Rails
Aliasing resources in Ruby on Rails

Earlier today, a friend working on a project asked me how we approached routes on our website. If you take a quick peak at our website, you’ll see that we have URLs like so: http://planetargon.com/ http://planetargon.com/who-we-are http://planetargon.com/who-we-are/robby-russellI couldn’t remember where I came across this before and wasn’t quickly finding it in the Ruby on Rails API, so...
Read more »

Tags: , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Howdy Rip!

June 11, 2009
By Robby Russell at Robby on Rails
Howdy Rip!

Chris Wanstrath (@defunkt) just posted the following on twitter. “Hello Rip – http://hellorip.com/“The Rip project describes itself as, “an attempt to create a next generation packaging system for Ruby.”One of the cool features is that it supports multiple environments. For example, you can have different Rip environments (with different gem versioning) that are targeted towards...
Read more »

Tags: , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

Hello, HeyBrainstormr.com

June 3, 2009
By Robby Russell at Robby on Rails
Hello, HeyBrainstormr.com

If you follow me on twitter, you might have heard that we launched a little project that we’ve been cooking up at Planet Argon. (news post)HeyBrainstormr is a lightweight web application that we created so that we could start a brainstorm on a specific topic and solicit ideas from each other. That’s all it...
Read more »

Tags: , , , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments

82,520 minutes on Phusion Passenger

April 10, 2009
By Robby Russell at Robby on Rails
82,520 minutes on Phusion Passenger

It’s been over 83,520 minutes since I made the switch from using mongrel as my development environment web server to Phusion Passenger. I’ve been extremely impressed with it. Our team has all switched over and haven’t really hit any obstacles in the transition.Since some people asked me to let them know how this trial...
Read more »

Tags: , , , , , , , , , , , ,
Posted in Publishers, Robby on Rails | View Comments