Skip to content

Instantly share code, notes, and snippets.

@picatz
Created December 27, 2016 21:06
Show Gist options
  • Save picatz/41463c279bc72252cb769636e3941f44 to your computer and use it in GitHub Desktop.
Save picatz/41463c279bc72252cb769636e3941f44 to your computer and use it in GitHub Desktop.
require 'sinatra'
require 'tilt/erubis'
require 'chartkick'
require 'time'
class CustomLogParser
# CustomLogParser code...
end
parser = CustomLogParser.new(:file => 'sample.log')
get '/' do
erb :index
end
get '/timeline' do
@timeline = parser.timeline
erb :timeline
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment