[Rails3] How to define RAILS_ENV for rake?

With Rails3, it is no longer possible (well soon to be deprecated) to do:

$ RAILS_ENV=test rake db:migrate

So what's the new way of doing it?

I believe it is still ok to use RAILS_ENV as an environment variable outside of Rails, but you want to use Rails.env in your code.

Sarah http://www.ultrasaurus.com/