aboutsummaryrefslogtreecommitdiffstats
path: root/BUILD
blob: 5c33efbd86550806e22a413d7c8dc4dadcb92611 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
load("//tools/bzl:plugin.bzl", "PLUGIN_DEPS", "PLUGIN_TEST_DEPS", "gerrit_plugin")
load("//tools/bzl:js.bzl", "gerrit_js_bundle")
load("//tools/bzl:junit.bzl", "junit_tests")

gerrit_plugin(
    name = "gerrit-plugin-gitconfig",
    manifest_entries = [
        "Gerrit-PluginName: gerrit-plugin-gitconfig",
        "Gerrit-Module: com.google.gerrit.plugins.gitconfig.GitConfigModule",
        "Gerrit-HttpModule: com.google.gerrit.plugins.gitconfig.GitConfigHttpModule",
        "Implementation-Title: Gerrit Gitconfig Plugin",
    ],
    srcs = glob(["src/main/java/**/*.java"]),
    resource_jars = [":gitconfig-ui"],
    resources = glob(["src/main/resources/**/*"]),
)

gerrit_js_bundle(
    name = "gitconfig-ui",
    srcs = glob([
        "src/main/resources/static/**/*.js",
    ]),
    entry_point = "src/main/resources/static/git-config-admin.js",
)

junit_tests(
    name = "tests",
    srcs = glob(["src/test/java/**/*.java"]),
    resources = glob(["src/test/resources/**"]),
    deps = PLUGIN_TEST_DEPS + PLUGIN_DEPS + [
        ":gerrit-plugin-gitconfig",
        "//java/com/google/gerrit/testing:gerrit-test-util",
        "//lib:jgit",
        "@jgit//org.eclipse.jgit.junit:junit"
    ],
)