| # Copyright 2023 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| # TODO(b/301136767): Don't assume these shared shac checks are always located here. |
| # Generate this file. |
| tools_dir = "third_party/fuchsia-infra-bazel-rules/shac/tools/" |
| vendor_dir = tools_dir + "vendor/" |
| |
| load("cpp/clang_format.star", "clang_format") |
| load("bazel/buildifier.star", "buildifier") |
| load("python/black.star", "black") |
| |
| def register_checks(): |
| shac.register_check(clang_format.with_args(tool = vendor_dir + "clang_format")) |
| shac.register_check(buildifier.with_args(tool = vendor_dir + "buildifier")) |
| shac.register_check(black.with_args(tool = vendor_dir + "black")) |
| |
| # TODO: json-fmt.py needs python. |
| # Setup a python CIPD dependency, or find a different json formatting tool. |
| #shac.register_check(json_formatter.with_args(tool = tools_dir + "json-fmt.py")) |