d347f025e7
zip was earlier introduced to avoid problems with Bazel's zipper, which tried to rename things where it couldn't. The standard zip stores timestamps, leading to spurious rebuilds, especially when building in IntelliJ. Change-Id: I7174e14e397da1c6774f543284009b307e982cce
18 lines
476 B
Python
18 lines
476 B
Python
load("//tools/bzl:genrule2.bzl", "genrule2")
|
|
|
|
genrule2(
|
|
name = "query",
|
|
srcs = ["com/google/gerrit/index/query/Query.g"],
|
|
outs = ["query_antlr.srcjar"],
|
|
cmd = " && ".join([
|
|
"$(location //lib/antlr:antlr-tool) -o $$TMP $<",
|
|
"cd $$TMP",
|
|
"find . -exec touch -t 198001010000 '{}' ';'",
|
|
"zip -q $$ROOT/$@ $$(find . -type f)",
|
|
]),
|
|
tools = [
|
|
"//lib/antlr:antlr-tool",
|
|
],
|
|
visibility = ["//visibility:public"],
|
|
)
|