tailog 0.1.4 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: fa5ccc4fd2d81e1b79f13d137f3ab99122e4a861
4
- data.tar.gz: 4b3bb33bbb3aca08b6ecde0cf8e3886d275cf4d3
3
+ metadata.gz: 8ebbb90d9b6b896c5d9c4090c4decb7ad7c3acee
4
+ data.tar.gz: 7d95e448fd6c8c385e47cce7b6a3283f60203950
5
5
  SHA512:
6
- metadata.gz: 412f9df31e82346139ef4af38eb22799b537ee30689d392d1a2a0f4d914c00c6b3e695a9ba6d9d2d89b99b4051756eaea75ae92e8fbe4fbdc1ac7413444d0dfb
7
- data.tar.gz: a0ff25025f9c809ab1da1756410819c556f17b30f559fd76d53d0f176415d9e6c418bf06c540f124581f2c35da4e0d5c62b33ef4dda32bc5cf06b20f5fe8e7b7
6
+ metadata.gz: 1ad18187d3b455ab7bec5dea5ceb3f55ddb374162f6b31b5643c4bcce23f591374b284a8ba2b3aaceebabe489bde2d90f81b3279e358debc01ecc300e8c0d2d9
7
+ data.tar.gz: 288094d8d02695e9f016e66c33c6ec14bbc461e9d434a77470427a7164e08812dd76c4818cf38ee973daed5ae5170e40b583c3d91e60e2660d0d0bcadf54666a
data/app/views/index.erb CHANGED
@@ -56,11 +56,12 @@
56
56
  </div><!--/.container-fluid -->
57
57
  </nav>
58
58
 
59
- <% if params[:file] %>
60
- <% file_path = File.join Tailog.log_path, params[:file] %>
61
- <h3 class="page-header monospace"><%= file_path %></h3>
59
+ <% begin %>
60
+
61
+ <% if params[:file] %>
62
+ <% file_path = File.join Tailog.log_path, params[:file] %>
63
+ <h3 class="page-header monospace"><%= file_path %></h3>
62
64
 
63
- <% begin %>
64
65
  <% File.open file_path do |file| %>
65
66
 
66
67
  <div id="content" class="monospace">
@@ -99,20 +100,20 @@
99
100
 
100
101
  <% end %>
101
102
 
102
- <% rescue => error %>
103
- <div class="alert alert-danger">
104
- <h4><%= h error.class %>: <%= h error.message %></h4>
105
- <% error.backtrace.each do |backtrace| %>
106
- <%= h backtrace %><br>
103
+ <% else %>
104
+ <div id="content" class="monospace">
105
+ <% Dir[File.join Tailog.log_path, '**/*.log'].each do |file| %>
106
+ <% relative_file = Pathname.new(file).relative_path_from(Pathname.new(Tailog.log_path)) %>
107
+ <a href="?file=<%= relative_file %>"><%= file %></a>
107
108
  <% end %>
108
109
  </div>
109
110
  <% end %>
110
111
 
111
- <% else %>
112
- <div id="content" class="monospace">
113
- <% Dir[File.join Tailog.log_path, '**/*.log'].each do |file| %>
114
- <% relative_file = Pathname.new(file).relative_path_from(Pathname.new(Tailog.log_path)) %>
115
- <a href="?file=<%= relative_file %>"><%= file %></a>
112
+ <% rescue => error %>
113
+ <div class="alert alert-danger">
114
+ <h4><%= h error.class %>: <%= h error.message %></h4>
115
+ <% error.backtrace.each do |backtrace| %>
116
+ <%= h backtrace %><br>
116
117
  <% end %>
117
118
  </div>
118
119
  <% end %>
@@ -1,3 +1,3 @@
1
1
  module Tailog
2
- VERSION = "0.1.4"
2
+ VERSION = "0.1.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tailog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - bbtfr