blob: 71f32e682bdfd48bed59da1cc3e626e3d1bcc192 [file] [log] [blame]
checkstyle_source = 'src/main/resources/onos/checkstyle.xml'
suppression_source = 'src/main/resources/onos/suppressions.xml'
xml = ('<module name="SuppressionFilter">'
'<property name="file" value="$(location :suppressions.xml)"/>'
'</module>' )
cmd = "sed 's#<module name=\"Checker\">#<module name=\"Checker\">%s#' %s > $OUT" % ( xml, checkstyle_source )
genrule(
name = 'checkstyle-xml',
srcs = [ checkstyle_source ],
out = 'checkstyle.xml',
bash = cmd,
visibility = [ 'PUBLIC' ]
)
export_file(
name = 'suppressions.xml',
src = suppression_source,
)