| David Ostrovsky | ff7c81a | 2016-11-20 23:27:10 +0100 | [diff] [blame^] | 1 | load("@com_googlesource_gerrit_bazlets//tools:classpath.bzl", "classpath_collector") |
| 2 | load("@com_googlesource_gerrit_bazlets//tools:py_binary_path.bzl", "py_binary_path") |
| 3 | |
| 4 | DEPS = [ |
| 5 | "//gitiles-servlet:servlet", |
| 6 | "//gitiles-dev:lib", |
| 7 | ] |
| 8 | |
| 9 | java_library( |
| 10 | name = "classpath", |
| 11 | runtime_deps = DEPS, |
| 12 | ) |
| 13 | |
| 14 | classpath_collector( |
| 15 | name = "main_classpath_collect", |
| 16 | testonly = 1, |
| 17 | deps = DEPS + [ |
| 18 | "//gitiles-servlet:servlet_tests", |
| 19 | ], |
| 20 | ) |
| 21 | |
| 22 | # TODO(davido): This is a hack: |
| 23 | # https://github.com/bazelbuild/bazel/issues/2452 |
| 24 | # We know the py_binary rule, but for *reasons* we cannot |
| 25 | # use `buck run <rule>. Unfortunately, a query to retrieve |
| 26 | # the path was removed in Bazel. So we are forced to do this |
| 27 | # hack to access python script outside of the Bazel. |
| 28 | py_binary_path( |
| 29 | name = "project.py", |
| 30 | py_binary_label = "@com_googlesource_gerrit_bazlets//tools/eclipse:project", |
| 31 | ) |