<% if params[:file] %>
<% file_path = File.join Tailog.log_path, params[:file] %>
<% begin %>
<% File.open file_path do |file| %>
<% file_size = file.size %>
<% file.tail(100).each do |line| %>
<%= h line %>
<% end %>
<% Dir[File.join Tailog.log_path, '**/*.log'].each do |file| %>
<% relative_file = Pathname.new(file).relative_path_from(Pathname.new(Tailog.log_path)) %>
<%= file %>
<% end %>