UebelAndre | 52c87aa | 2021-06-01 14:18:58 -0700 | [diff] [blame] | 1 | # `.bazelrc` is a Bazel configuration file. |
UebelAndre | acca6f4 | 2022-03-01 06:59:47 -0800 | [diff] [blame] | 2 | # https://bazel.build/docs/best-practices#bazelrc-file |
UebelAndre | 52c87aa | 2021-06-01 14:18:58 -0700 | [diff] [blame] | 3 | |
Daniel Wagner-Hall | f5813fa | 2023-06-02 12:34:55 +0100 | [diff] [blame] | 4 | # Required on windows |
| 5 | common --enable_platform_specific_config |
Daniel Wagner-Hall | 1b63651 | 2023-06-14 15:27:22 +0100 | [diff] [blame] | 6 | startup --windows_enable_symlinks |
Daniel Wagner-Hall | f5813fa | 2023-06-02 12:34:55 +0100 | [diff] [blame] | 7 | build:windows --enable_runfiles |
| 8 | |
UebelAndre | 52c87aa | 2021-06-01 14:18:58 -0700 | [diff] [blame] | 9 | # Enable rustfmt for all targets in the workspace |
| 10 | build:rustfmt --aspects=@rules_rust//rust:defs.bzl%rustfmt_aspect |
| 11 | build:rustfmt --output_groups=+rustfmt_checks |
UebelAndre | ed64716 | 2021-07-10 09:22:07 -0700 | [diff] [blame] | 12 | |
| 13 | # Enable clippy for all targets in the workspace |
| 14 | build:clippy --aspects=@rules_rust//rust:defs.bzl%rust_clippy_aspect |
| 15 | build:clippy --output_groups=+clippy_checks |
UebelAndre | acca6f4 | 2022-03-01 06:59:47 -0800 | [diff] [blame] | 16 | |
Yun Peng | a458757 | 2023-10-06 18:01:55 +0200 | [diff] [blame] | 17 | # TODO: migrate all dependencies from WORKSPACE to MODULE.bazel |
| 18 | # https://github.com/bazelbuild/rules_rust/issues/2181 |
| 19 | common --noenable_bzlmod |
| 20 | |
Daniel Wagner-Hall | 53daac7 | 2024-02-22 14:59:10 +0000 | [diff] [blame] | 21 | # This isn't currently the defaut in Bazel, but we enable it to test we'll be ready if/when it flips. |
| 22 | build --incompatible_disallow_empty_glob |
| 23 | |
Daniel Wagner-Hall | bb73b64 | 2024-06-14 09:46:12 +0100 | [diff] [blame] | 24 | build --java_runtime_version=remotejdk_21 |
| 25 | build --java_language_version=21 |
| 26 | build --tool_java_runtime_version=remotejdk_21 |
| 27 | build --tool_java_language_version=21 |
| 28 | |
UebelAndre | acca6f4 | 2022-03-01 06:59:47 -0800 | [diff] [blame] | 29 | # This import should always be last to allow users to override |
| 30 | # settings for local development. |
| 31 | try-import %workspace%/user.bazelrc |