Hashar has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/385379 )

Change subject: Rakefile: wmf_style format now support KIND
......................................................................

Rakefile: wmf_style format now support KIND

In puppet-lint 'KIND' is the uppercase version of 'kind'. The Jenkins
plugins expect the uppercased flavor.

Inject it in the problems hash the same way PuppetLint::report does.

Example run:

$ JENKINS_URL=1 bundle exec rake global:wmf_style
modules/admin/manifests/init.pp:17:wmf_styleguide:ERROR:wmf-style: class
'admin' includes sudo from another module
modules/apache/manifests/monitoring.pp:10:wmf_styleguide:ERROR:wmf-style:
class 'apache::monitoring' includes standard from another module

Change-Id: Iaaee7825dc14eaba25182ef4d21cdaa836d7d432
---
M Rakefile
M rake_modules/taskgen.rb
2 files changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/79/385379/1

diff --git a/Rakefile b/Rakefile
index 9799c49..1e50b08 100644
--- a/Rakefile
+++ b/Rakefile
@@ -95,7 +95,7 @@
       next if linter.problems.empty?
 
       if ENV.key?('JENKINS_URL')
-          t.print_wmf_style_violations linter.problems, nil, 
'%{path}:%{line}:%{check}:%{kind}:%{message}'
+          t.print_wmf_style_violations linter.problems, nil, 
'%{path}:%{line}:%{check}:%{KIND}:%{message}'
       else
           t.print_wmf_style_violations linter.problems
       end
diff --git a/rake_modules/taskgen.rb b/rake_modules/taskgen.rb
index 9cfa592..e406989 100644
--- a/rake_modules/taskgen.rb
+++ b/rake_modules/taskgen.rb
@@ -48,6 +48,7 @@
       other.select { |x| x[:message] == p[:message] && x[:path] == p[:path] 
}.empty?
     end
     events.each do |p|
+      p[:KIND] = p[:kind].to_s.upcase
       puts format(format, p)
     end
     puts "Nothing found" if events.length.zero?

-- 
To view, visit https://gerrit.wikimedia.org/r/385379
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaaee7825dc14eaba25182ef4d21cdaa836d7d432
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Hashar <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to