-
Notifications
You must be signed in to change notification settings - Fork 24
Expand file tree
/
Copy pathRakefile
More file actions
30 lines (24 loc) · 759 Bytes
/
Rakefile
File metadata and controls
30 lines (24 loc) · 759 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be
# available to Rake.
require_relative "config/application"
Rails.application.load_tasks
if Rails.env.local?
desc "Run Rubocop"
task rubocop: :environment do
sh "bundle exec rubocop"
end
desc "Run Slim Lint"
task slim_lint: :environment do
sh "bundle exec slim-lint app/views app/components"
end
desc "Run Brakeman"
task brakeman: :environment do
# CI env var makes Brakeman not put its output in a pager
sh "CI=true bundle exec brakeman"
end
desc "Run all linters"
task lint: %i[rubocop slim_lint brakeman]
desc "Run all linters and specs"
task default: %i[lint spec]
end