Thomas Vachuska | 6c75a76 | 2018-07-19 09:28:33 -0700 | [diff] [blame] | 1 | load("//tools/build/bazel:generate_workspace.bzl", "maven_coordinates") |
2 | |||||
3 | # Example invocation: | ||||
4 | # bazel build $(bazel query 'kind("_bnd rule", //...)') \ | ||||
5 | # --aspects tools/build/bazel/mvn_jar.bzl%print_mvn_jar 2>&1 | \ | ||||
6 | # egrep "DEBUG: .*mvn_jar.bzl" | cut -d\ -f3- | ||||
7 | |||||
8 | def _impl(target, ctx): | ||||
9 | [ print (maven_coordinates(target.label), f.path) for f in target.files ] | ||||
10 | return [] | ||||
11 | |||||
12 | print_mvn_jar = aspect( | ||||
13 | implementation = _impl, | ||||
14 | ) |