brakeman-min 4.0.0 → 4.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES +5 -0
- data/lib/brakeman.rb +7 -3
- data/lib/brakeman/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: 730e9fa0a5a00feba7a5c64d6cdb6e5eabc914da
|
4
|
+
data.tar.gz: 1b75b40d02c13de9191aa9a5f6643d2609ec3a78
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9d35409bcb12d0790b5b8cbb0ba90137caff38bcd7d0bfebca7cd039e2964197e4422b77be305eaa8daaf10ef8b22b9c675c55b24c8f75ebc8f70f31f3ec187b
|
7
|
+
data.tar.gz: 4bdd9e7f614bde8928b4d3722d6f49e40136db09bcdfb247a9a2ea9642cc04f2f10a3e1b247c85b9d8ad0826f6982037c3ba4fe5703a5eab26c515bd66139c0b
|
data/CHANGES
CHANGED
data/lib/brakeman.rb
CHANGED
@@ -408,7 +408,11 @@ module Brakeman
|
|
408
408
|
private_class_method :write_report_to_formats
|
409
409
|
|
410
410
|
def self.page_output text
|
411
|
-
|
411
|
+
ci = ENV["CI"]
|
412
|
+
|
413
|
+
if ci.is_a? String and ci.downcase == "true"
|
414
|
+
puts text
|
415
|
+
elsif system("which less")
|
412
416
|
# Adapted from https://github.com/piotrmurach/tty-pager/
|
413
417
|
write_io = open("|less -R", 'w')
|
414
418
|
pid = write_io.pid
|
@@ -421,7 +425,7 @@ module Brakeman
|
|
421
425
|
load_brakeman_dependency 'highline'
|
422
426
|
h = ::HighLine.new
|
423
427
|
h.page_at = :auto
|
424
|
-
h.say
|
428
|
+
h.say text
|
425
429
|
end
|
426
430
|
rescue Errno::ECHILD
|
427
431
|
# on jruby 9x waiting on pid raises (per tty-pager)
|
@@ -429,7 +433,7 @@ module Brakeman
|
|
429
433
|
rescue => e
|
430
434
|
warn "[Error] #{e}"
|
431
435
|
warn "[Error] Could not use pager. Set --no-pager to avoid this issue."
|
432
|
-
puts
|
436
|
+
puts text
|
433
437
|
end
|
434
438
|
|
435
439
|
#Rescan a subset of files in a Rails application.
|
data/lib/brakeman/version.rb
CHANGED