Commit 5de4b4ef by David Baumgold

Refactor rake tasks for pylint/pep8

Split components with : instead of _
parent 8dd32b2a
...@@ -20,26 +20,26 @@ end ...@@ -20,26 +20,26 @@ end
report_dir = report_dir_path(system) report_dir = report_dir_path(system)
directory report_dir directory report_dir
desc "Run pep8 on all #{system} code" namespace :pylint do
task "pep8_#{system}" => [report_dir, :install_python_prereqs] do namespace system do
sh("pep8 #{system} | tee #{report_dir}/pep8.report") desc "Run pylint checking for #{system} checking for errors only, and aborting if there are any"
task :errors do
run_pylint(system, report_dir, '-E')
end
end end
task :pep8 => "pep8_#{system}"
desc "Run pylint on all #{system} code" desc "Run pylint on all #{system} code"
task "pylint_#{system}" => [report_dir, :install_python_prereqs] do task system do
run_pylint(system, report_dir) run_pylint(system, report_dir)
end end
namespace "pylint_#{system}" do
desc "Run pylint checking for errors only, and aborting if there are any"
task :errors do
run_pylint(system, report_dir, '-E')
end end
task :pylint => :"pylint:#{system}"
namespace :pep8 do
desc "Run pep8 on all #{system} code"
task system => [report_dir, :install_python_prereqs] do
sh("pep8 #{system} | tee #{report_dir}/pep8.report")
end end
namespace :pylint do
task :errors => "pylint_#{system}:errors"
end end
task :pep8 => :"pep8:#{system}"
task :pylint => "pylint_#{system}"
end end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment