Presets for bazelrc
Blog post from Aspect Build
Bazel, a complex build and test tool, offers an overwhelming number of options, exceeding 1500, which can lead to confusion, especially for new users who may encounter bugs due to default settings not being optimal for new repositories. To alleviate this, users can utilize presets, which are named .bazelrc files containing sets of flags accompanied by explanations and links to further documentation, designed to provide more sensible default values. These presets can be integrated into projects by adding a dependency on bazel-lib, copying the presets into the repository using a provided macro, and updating the .bazelrc file to import relevant presets. While the community is encouraged to suggest improvements to these presets via an open-source repository, efforts are also underway to address the underlying issue of suboptimal default settings through community-driven bug bounties, though participation has been limited.