Commit 374ce67e by Calen Pennington

Run pep8 and pylint on all libraries, not just the lms

parent 1d1af3be
...@@ -44,17 +44,17 @@ task :default => [:pep8, :pylint, :test] ...@@ -44,17 +44,17 @@ task :default => [:pep8, :pylint, :test]
directory REPORT_DIR directory REPORT_DIR
directory LMS_REPORT_DIR directory LMS_REPORT_DIR
desc "Run pep8 on all of djangoapps" desc "Run pep8 on all libraries"
task :pep8 => LMS_REPORT_DIR do task :pep8 => REPORT_DIR do
sh("pep8 --ignore=E501 lms/djangoapps | tee #{LMS_REPORT_DIR}/pep8.report") sh("pep8 --ignore=E501 lms/djangoapps common/lib/* | tee #{REPORT_DIR}/pep8.report")
end end
desc "Run pylint on all of djangoapps" desc "Run pylint on all libraries"
task :pylint => LMS_REPORT_DIR do task :pylint => REPORT_DIR do
ENV['PYTHONPATH'] = 'lms/djangoapps' Dir["lms/djangoapps/*", "common/lib/*"].each do |app|
Dir["lms/djangoapps/*"].each do |app| ENV['PYTHONPATH'] = File.dirname(app)
app = File.basename(app) app = File.basename(app)
sh("pylint -f parseable #{app} | tee #{LMS_REPORT_DIR}/#{app}.pylint.report") sh("pylint -f parseable #{app} | tee #{REPORT_DIR}/#{app}.pylint.report")
end end
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