Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ bazel_dep(name = "rules_python", version = "0.19.0")
bazel_dep(name = "platforms", version = "0.0.7")
bazel_dep(name = "cgrindel_bazel_starlib", version = "0.18.0")

# not a direct dependency, but required here for bazel starlib's difftest macros to work
bazel_dep(
name = "buildifier_prebuilt",
version = "6.1.2",
)

register_toolchains("@bazel_tools//tools/python:autodetecting_toolchain")

# Must keep the Bazel version listed in WORKSPACE in sync with those loaded
Expand Down
65 changes: 45 additions & 20 deletions MODULE.bazel.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions shared.bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,10 @@ common --color=auto --curses=auto

# Enable bzlmod
common --enable_bzlmod

# Required for windows
startup --windows_enable_symlinks

# this library requires runfiles for the bzlformat_lint_test
# but this is off by default on windows. Switch it on.
common --enable_runfiles
4 changes: 4 additions & 0 deletions tests/tools_tests/remove_child_wksp_bazel_symlinks_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ child_a_bazel_out="${bazel_out}/child_a"
child_b_bazel_out="${bazel_out}/child_b"
mkdir -p "${bazel_out}" "${child_a_bazel_out}" "${child_b_bazel_out}" "${parent_bazel_out}"

# Windows requires this for msys to create real symlinks
# https://superuser.com/questions/1097481/msys2-create-a-sym-link-into-windows-folder-location
export MSYS=winsymlinks:nativestrict

# Add bazel symlinks
parent_symlink="${parent_dir}/bazel-parent"
child_a_symlink="${child_a_dir}/bazel-child_a"
Expand Down
3 changes: 3 additions & 0 deletions tests/tools_tests/setup_test_workspace.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ bazelrc_template="
build --deleted_packages=
query --deleted_packages=
# EOF"
# todo: should these lines be in the template above?
# startup --windows_enable_symlinks
# common --enable_runfiles

reset_bazelrc_files() {
for bazelrc in "${bazelrcs[@]}" ; do
Expand Down