guard-brakeman 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/README.md +1 -2
  2. data/lib/guard/brakeman.rb +4 -1
  3. metadata +3 -3
data/README.md CHANGED
@@ -50,8 +50,7 @@ Please read the [Guard documentation](http://github.com/guard/guard#readme) for
50
50
  ### List of available options
51
51
 
52
52
  ```ruby
53
- :output_file => 'donkey' # write the results to the specified file, optinally supply extension which will be used for :output_format
54
- :output_format => 'html' # specify the output format
53
+ :output_file => 'donkey.html' # write the results to the specified file
55
54
  :notifications => false # display Growl notifications, defaults to true
56
55
  :run_on_start => true # run all checks on startup, defaults to false
57
56
  :min_confidence => 3 # only alert on warnings above a threshold, defaults to 1
@@ -37,7 +37,10 @@ module Guard
37
37
  #
38
38
  def start
39
39
  @scanner_opts = ::Brakeman::set_options({:app_path => '.'}.merge(@options))
40
+ @options.merge!(@scanner_opts)
41
+
40
42
  @scanner = ::Brakeman::Scanner.new(@scanner_opts)
43
+
41
44
  @tracker = @scanner.process
42
45
 
43
46
  if @options[:run_on_start]
@@ -157,7 +160,7 @@ module Guard
157
160
 
158
161
  def write_report
159
162
  File.open @options[:output_file], "w" do |f|
160
- f.puts @tracker.report.send(@scanner_opts[:output_format])
163
+ f.puts @tracker.report.send(@options[:output_format])
161
164
  end
162
165
  end
163
166
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guard-brakeman
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
- - 0
10
- version: 0.3.0
9
+ - 1
10
+ version: 0.3.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Neil Matatall