mattmatt/lograge — pull request #4 by adamcooper (2012-03-27 04:08:39+00:00)
Title: Adding a hook to allow custom data to the rage line

This adds a new hook that allows someone to add additional logging onto the one line log.

I realize that this is pretty opinionated gem but I figured there are a couple cases where putting a bit of extra information may be nice. The use case I need it for was to put a bit of information about GC stats run and I wanted to be able to easily grep and look at this data from the log file.

Here is how you would add an extra bit of information to the log line.

```ruby
# config/environments/staging.rb
MyApp::Application.configure do
config.lograge.enabled = true
config.lograge.extra = lambda do |event|
# some custom details
" custom data like GC stats"
end
end
```

This patch also includes specs and doc updates.

BTW, There is another hidden feature in here and that is a fix to issue #1. At least in development mode. It should also work in the case where ```rack_cache == false```. This is in it's own commit so you can take one without other.