blob: 5d1656cecef2c7969b62a913f83a047ac4ff758e [file] [log] [blame]
load("@aspect_rules_js//js:defs.bzl", "js_run_binary")
def normalize_xliff_files(name, srcs, outs, visibility = ["//visibility:private"]):
if len(srcs) != len(outs):
fail("srcs and outs should have the same length.")
args = []
for idx in range(len(srcs)):
args.append("$(rootpath {})".format(srcs[idx]))
args.append("$(rootpath {})".format(outs[idx]))
js_run_binary(
name = name,
srcs = srcs,
outs = outs,
args = args,
tool = Label(":normalize_xliff_files"),
visibility = visibility,
)