diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2009-11-19 15:24:00 -0800 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2009-11-19 15:24:00 -0800 |
commit | c7c39f52dcce4ea6de2051ee7816c0cb9d583f8f (patch) | |
tree | 2ea73ce578cb72a70c86a744c76615890535161b /railties/lib/rails/rack/log_tailer.rb | |
parent | 5df26dd7a91bb6d248b96c4308242a51ab59aa5c (diff) | |
download | rails-c7c39f52dcce4ea6de2051ee7816c0cb9d583f8f.tar.gz rails-c7c39f52dcce4ea6de2051ee7816c0cb9d583f8f.tar.bz2 rails-c7c39f52dcce4ea6de2051ee7816c0cb9d583f8f.zip |
Revert "Final steps toward clean rails "foo"; cd foo; gem bundle; script/server working"
Broke stuff.
This reverts commit 520b8b59110dd130c89b317b6bd65d8644c7836f.
Diffstat (limited to 'railties/lib/rails/rack/log_tailer.rb')
-rw-r--r-- | railties/lib/rails/rack/log_tailer.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/railties/lib/rails/rack/log_tailer.rb b/railties/lib/rails/rack/log_tailer.rb index f3ebebf67d..a237cee6bc 100644 --- a/railties/lib/rails/rack/log_tailer.rb +++ b/railties/lib/rails/rack/log_tailer.rb @@ -1,11 +1,12 @@ module Rails module Rack class LogTailer + EnvironmentLog = "#{File.expand_path(Rails.root)}/log/#{Rails.env}.log" + def initialize(app, log = nil) - @default_log = "#{File.expand_path(Rails.root)}/log/#{Rails.env}.log" @app = app - path = Pathname.new(log || @default_log).cleanpath + path = Pathname.new(log || EnvironmentLog).cleanpath @cursor = ::File.size(path) @last_checked = Time.now.to_f |