stash-query 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/stash-query/query.rb +4 -1
- data/lib/stash-query/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dfe167aa7e4566dfd8a252ef7509fe1790c8c6fc
|
4
|
+
data.tar.gz: c2039cd7e74ab550c09a82150345dc2fa3eea1c3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e1173c31b06e1b53405f956756d8282277914af1caa4239a9e143e168eaf2339576a0a581b74ed01c7d912eb7bb75f3a97bdfdf97d207be31f26808672d212ea
|
7
|
+
data.tar.gz: 0ba308509044f132f5a0046c53ccdb5627a56d6fb9c44eea3158773fcebe6cff6a90234a031dd8b0717c99b8d7b8a117700a96c19c4d8275680d5fa447dad2b3
|
data/lib/stash-query/query.rb
CHANGED
@@ -85,6 +85,9 @@ module Stashquery
|
|
85
85
|
|
86
86
|
def flush_to_file(hit_list)
|
87
87
|
return if @config[:output].nil?
|
88
|
+
if hit_list.is_a? String
|
89
|
+
hit_list = hit_list.split("\n")
|
90
|
+
end
|
88
91
|
File.open(@config[:output], 'a') do |file|
|
89
92
|
begin
|
90
93
|
file.puts(generate_output(hit_list))
|
@@ -225,7 +228,7 @@ module Stashquery
|
|
225
228
|
bar.increment! if @config[:print]
|
226
229
|
hit_list << hit
|
227
230
|
if hit_list.length % $flush_buffer == 0
|
228
|
-
flush_to_file hit_list
|
231
|
+
flush_to_file hit_list
|
229
232
|
hit_list = Array.new
|
230
233
|
end
|
231
234
|
end
|
data/lib/stash-query/version.rb
CHANGED