load("@rules_python//python:defs.bzl", "py_binary")

exports_files([
    "_event_manager.py",
    "_network_handlers.py",
    "_script_handlers.py",
    "bidi_enhancements_manifest.py",
    "cdp.py",
])

py_binary(
    name = "merge_cddl",
    srcs = ["merge_cddl.py"],
    legacy_create_init = False,
    visibility = [
        "//javascript/selenium-webdriver:__pkg__",
        "//py:__pkg__",
    ],
)

py_binary(
    name = "untar",
    srcs = [
        "untar.py",
    ],
    legacy_create_init = False,
    visibility = ["//visibility:public"],
)

py_binary(
    name = "ruff",
    srcs = ["ruff.py"],
    data = [
        "//py:pyproject.toml",
        "@multitool//tools/ruff",
    ],
    visibility = ["//visibility:public"],
    deps = ["@rules_python//python/runfiles"],
)

py_binary(
    name = "ruff_check",
    srcs = ["ruff.py"],
    args = ["check"],
    data = [
        "//py:pyproject.toml",
        "@multitool//tools/ruff",
    ],
    main = "ruff.py",
    visibility = ["//visibility:public"],
    deps = ["@rules_python//python/runfiles"],
)

py_binary(
    name = "ruff_format",
    srcs = ["ruff.py"],
    args = ["format"],
    data = [
        "//py:pyproject.toml",
        "@multitool//tools/ruff",
    ],
    main = "ruff.py",
    visibility = ["//visibility:public"],
    deps = ["@rules_python//python/runfiles"],
)
