From 2c6141c8ae54f17cfb3091231dce0dde7212736b Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 8 Jun 2010 19:35:42 +0000 Subject: unicorn_rails: fix requires for Ruby 1.9.2 Ruby 1.9.2 no longer includes "." in $LOAD_PATH, so we need to require using an explicit path. This issue only affected Rails 3 users who chose to run without the default config.ru, as the config.ru generated by Rails 3 will call File.expand_path in the same way. --- bin/unicorn_rails | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/unicorn_rails b/bin/unicorn_rails index ed235ba..219f962 100755 --- a/bin/unicorn_rails +++ b/bin/unicorn_rails @@ -132,8 +132,8 @@ def rails_builder(daemonize) lambda do || # Load Rails and (possibly) the private version of Rack it bundles. begin - require 'config/boot' - require 'config/environment' + require ::File.expand_path('config/boot') + require ::File.expand_path('config/environment') rescue LoadError => err abort "#$0 must be run inside RAILS_ROOT: #{err.inspect}" end -- cgit v1.2.3-24-ge0c7