Description:
fix options bugs
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r233:4f1f5f158cc9 - - 1 file changed: 2 inserted, 2 deleted
@@ -20,7 +20,7 | |||||
|
20 | def process_options_and_stop_file |
|
20 | def process_options_and_stop_file |
|
21 |
|
21 | ||
|
22 | # Process 'help' option |
|
22 | # Process 'help' option |
|
23 | - if (ARGV.length==1) and (/help/.match(ARGV[0])) |
|
23 | + if (ARGV.length == 0) or ((ARGV.length==1) and (/help/.match(ARGV[0]))) |
|
24 | display_manual |
|
24 | display_manual |
|
25 | exit(0) |
|
25 | exit(0) |
|
26 | end |
|
26 | end |
@@ -74,7 +74,7 | |||||
|
74 | require RAILS_ROOT + '/config/environment' |
|
74 | require RAILS_ROOT + '/config/environment' |
|
75 |
|
75 | ||
|
76 | if options[:all] |
|
76 | if options[:all] |
|
77 |
- Problem.all.each { |prob| process_problem(prob,options[: |
|
77 | + Problem.all.each { |prob| process_problem(prob,options[:dry_run]) } |
|
78 | else |
|
78 | else |
|
79 | ARGV.each do |name| |
|
79 | ARGV.each do |name| |
|
80 | prob = Problem.find_by(name: name) |
|
80 | prob = Problem.find_by(name: name) |
You need to be logged in to leave comments.
Login now