Posts Tagged ‘ development ’

Sending email: Controllers versus Models

2009/11/16
By Robby Russell
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
  ...
end

Fairly 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

2009/11/14
By Robby Russell
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...
Read more »

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

Launching Ruby on Rails projects, the video

2009/11/11
By Robby Russell
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...
Read more »

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

Flash Message Conductor now a Gem

2009/10/13
By Robby Russell
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...
Read more »

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

Planting the seeds

2009/09/05
By Robby Russell
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

2009/06/22
By Robby Russell
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

2009/06/22
By Robby Russell
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:

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

Howdy Rip!

2009/06/11
By Robby Russell
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...
Read more »

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

Hello, HeyBrainstormr.com

2009/06/03
By Robby Russell
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...
Read more »

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

82,520 minutes on Phusion Passenger

2009/04/10
By Robby Russell
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...
Read more »

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