1

I'm adding handlebars to a Java project using bazel. The WORKSPACE installs the maven dependency:

...
"com.github.jknack:handlebars.java:4.3.1",
...

Within the BUILD file, how do I determine the dep name? In this case I'm doing:

deps = [
...
"@maven//:com_github_jknack_handlebars_java",
...
]

But this is mostly guess work and following patterns. I've looked over the bazel maven docs and I don't see anything covering how this target is referenced.

gph
  • 1,045
  • 8
  • 25

1 Answers1

0

I do something like this (query for all maven dependencies and filtering for the dependency I am looking for, e.g. junit):

bazel query "@maven//:*" | grep junit
Vertexwahn
  • 7,709
  • 6
  • 64
  • 90