File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -72,7 +72,9 @@ module YourCoolApp
72
72
class Application < Rails::Application
73
73
config.generators.after_generate do |files|
74
74
parsable_files = files.filter { |file| file.end_with?('.rb') }
75
- system("bundle exec rubocop -A --fail-level=E #{parsable_files.shelljoin}", exception: true)
75
+ unless parsable_files.empty?
76
+ system("bundle exec rubocop -A --fail-level=E #{parsable_files.shelljoin}", exception: true)
77
+ end
76
78
end
77
79
end
78
80
end
Original file line number Diff line number Diff line change @@ -42,7 +42,9 @@ module YourCoolApp
42
42
class Application < Rails::Application
43
43
config.generators.after_generate do |files|
44
44
parsable_files = files.filter { |file| file.end_with?('.rb') }
45
- system("bundle exec rubocop -A --fail-level=E #{parsable_files.shelljoin}", exception: true)
45
+ unless parsable_files.empty?
46
+ system("bundle exec rubocop -A --fail-level=E #{parsable_files.shelljoin}", exception: true)
47
+ end
46
48
end
47
49
end
48
50
end
You can’t perform that action at this time.
0 commit comments