Module: Onceover::CodeQuality::Lint
- Defined in:
- lib/onceover/codequality/lint.rb
Constant Summary collapse
- LINT_PATHS =
Apply linting to the manifests directory and each module under
site [ "manifests", ].concat(Dir.glob('site/*').select {|f| File.directory? f})
- LINT_OPTIONS =
[ "--relative", "--fail-on-warnings", "--no-double_quoted_strings-check", "--no-80chars-check", "--no-variable_scope-check", "--no-quoted_booleans-check", ]
Class Method Summary collapse
Class Method Details
.puppet ⇒ Object
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 |
# File 'lib/onceover/codequality/lint.rb', line 19 def self.puppet status = true LINT_PATHS.each { |p| if Dir.exists?(p) Dir.chdir(p) do logger.info("checking #{p}") if ! system("puppet-lint #{LINT_OPTIONS.join ' '} . ") status = false end end end } status end |