blob: ff48d8b5d050985b632dfbfc3447a5a6c888dc76 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
{%- if has_errorprone -%}
{%- set ep_flags = target.javac.flags|select('startsWith', '-Xep:') -%}
{%- if ep_flags|length or ep_opts|length %}
tasks.withType<JavaCompile> {
{%- if ep_flags|length %}
options.errorprone.checks.set(
mapOf(
{%- for ep_flag in ep_flags -%}
{%- set key_and_value = split(ep_flag|replace('-Xep:', ''), ':', 2) %}
"{{ key_and_value[0] }}" to CheckSeverity.{{ key_and_value[1] }},
{%- endfor %}
)
)
{% endif -%}
}
{% endif -%}
{%- endif -%}
|