-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
.bazelrc
98 lines (81 loc) · 4.38 KB
/
.bazelrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
# Common Bazel settings for JavaScript/NodeJS workspaces
# This rc file is automatically discovered when Bazel is run in this workspace,
# see https://docs.bazel.build/versions/master/guide.html#bazelrc
#
# The full list of Bazel options: https://docs.bazel.build/versions/master/command-line-reference.html
# Import Aspect recommended Bazel settings for all projects
import %workspace%/.aspect/bazelrc/bazel6.bazelrc
import %workspace%/.aspect/bazelrc/convenience.bazelrc
import %workspace%/.aspect/bazelrc/correctness.bazelrc
import %workspace%/.aspect/bazelrc/debug.bazelrc
import %workspace%/.aspect/bazelrc/performance.bazelrc
### YOUR PROJECT SPECIFIC SETTINGS GO HERE ###
common --enable_bzlmod
build --java_runtime_version=remotejdk_11
build --action_env=PATH=/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin
# Give me dem stack traces
build --verbose_failures
build --experimental_platform_in_output_dir
build --experimental_remote_cache_compression
build --legacy_important_outputs
build --remote_build_event_upload=minimal
build --noslim_profile
build --experimental_profile_include_target_label
build --experimental_profile_include_primary_output
common --bes_upload_mode=fully_async
# Bazel will create symlinks from the workspace directory to output artifacts.
# Build results will be placed in a directory called "dist/bin"
# Other directories will be created like "dist/testlogs"
# Be aware that this will still create a bazel-out symlink in
# your project directory, which you must exclude from version control and your
# editor's search path.
# To disable the symlinks altogether (including bazel-out) you can use
# build --symlink_prefix=/
# however this makes it harder to find outputs.
# Support for debugging NodeJS tests
# Add the Bazel option `--config=debug` to enable this
# --compilation_mode=dbg
# Rules may change their build outputs if the compilation mode is set to dbg. For example,
# mininfiers such as terser may make their output more human readable when this is set. Rules will pass `COMPILATION_MODE`
# to `nodejs_binary` executables via the actions.run env attribute.
# See https://docs.bazel.build/versions/master/user-manual.html#flag--compilation_mode for more details.
test:debug --define=VERBOSE_LOGS=1
run:debug --define=VERBOSE_LOGS=1
# The following option will change the build output of certain rules such as terser and may not be desirable in all cases
build:debug --compilation_mode=dbg
run --incompatible_strict_action_env
# Increase heap size
build --define=NODE_OPTIONS=--max-old-space-size=4096
# BuildBuddy GH Actions Config
# https://www.buildbuddy.io/docs/rbe-github-actions
build --bes_results_url=https://formatjs.buildbuddy.io/invocation/
build --bes_backend=grpcs://formatjs.buildbuddy.io
build --remote_cache=grpcs://formatjs.buildbuddy.io
# honor the setting of `skipLibCheck` in the tsconfig.json file
build --@aspect_rules_ts//ts:skipLibCheck=honor_tsconfig
fetch --@aspect_rules_ts//ts:skipLibCheck=honor_tsconfig
query --@aspect_rules_ts//ts:skipLibCheck=honor_tsconfig
# Use "tsc" as the transpiler when ts_project has no `transpiler` set.
build --@aspect_rules_ts//ts:default_to_tsc_transpiler
fetch --@aspect_rules_ts//ts:default_to_tsc_transpiler
query --@aspect_rules_ts//ts:default_to_tsc_transpiler
# BuildBuddy RBE
build:remote --remote_executor=grpcs://formatjs.buildbuddy.io
build:remote --host_platform=@buildbuddy_toolchain//:platform
build:remote --platforms=@buildbuddy_toolchain//:platform
build:remote --extra_execution_platforms=@buildbuddy_toolchain//:platform
build:remote --crosstool_top=@buildbuddy_toolchain//:toolchain
build:remote --extra_toolchains=@buildbuddy_toolchain//:cc_toolchain
build:remote --java_language_version=11
build:remote --tool_java_language_version=11
build:remote --java_runtime_version=remotejdk_11
build:remote --tool_java_runtime_version=remotejdk_11
build:remote --define=EXECUTOR=remote
# Load any settings specific to the current user.
# .bazelrc.user should appear in .gitignore so that settings are not shared with team members
# This needs to be last statement in this
# config, as the user configuration should be able to overwrite flags from this file.
# See https://docs.bazel.build/versions/master/best-practices.html#bazelrc
# (Note that we use .bazelrc.user so the file appears next to .bazelrc in directory listing,
# rather than user.bazelrc as suggested in the Bazel docs)
try-import %workspace%/.bazelrc.user