Public API for jq

Macros and Functions

jq

Invoke jq with a filter on a set of json input files.

For jq documentation, see https://stedolan.github.io/jq/.

Example usage (generated)

load("@aspect_bazel_lib//lib:jq.bzl", "jq")

jq(
    # Name of the rule
    name = "",
    # List of input json files
    srcs = [],
    # mandatory jq filter specification (https://stedolan.github.io/jq/manual/#Basicfilters)
    filter = None,
)

name

Name of the rule

srcs

List of input json files

filter

mandatory jq filter specification (https://stedolan.github.io/jq/manual/#Basicfilters)

args

additional args to pass to jq

out

Name of the output json file; defaults to the rule name plus ".json"