Skip to content

Commit

Permalink
Consider MODULE.bazel for workspace detection in bazel.sh
Browse files Browse the repository at this point in the history
Fixes #20509.

Closes #20510.

PiperOrigin-RevId: 590328908
Change-Id: I5023450d7c1e23ee52e9cd7291aaf843e7365cc2
  • Loading branch information
siddharthab authored and copybara-github committed Dec 12, 2023
1 parent 21ad24c commit e11506f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/packages/bazel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ function get_realpath() {
function get_workspace_root() {
workspace_dir="${PWD}"
while [[ "${workspace_dir}" != / ]]; do
if [[ -e "${workspace_dir}/WORKSPACE" || -e "${workspace_dir}/WORKSPACE.bazel" ]]; then
if [[ -e "${workspace_dir}/WORKSPACE" || -e "${workspace_dir}/WORKSPACE.bazel" || -e "${workspace_dir}/MODULE.bazel" ]]; then
readonly workspace_dir
return
fi
Expand Down

0 comments on commit e11506f

Please sign in to comment.