Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
8 changes: 4 additions & 4 deletions src/test/tools/bzlmod/MODULE.bazel.lock

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

2 changes: 2 additions & 0 deletions tools/build_defs/repo/utils.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@ def download_remote_files(ctx, auth = None):
auth = get_auth(ctx, remote_file_urls) if auth == None else auth,
integrity = ctx.attr.remote_file_integrity.get(path, ""),
block = False,
# Overlaid files may be shell scripts.
executable = True,
Comment on lines +110 to +111

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

Setting executable = True unconditionally might introduce unintended consequences. It would be safer to check if the file has a shebang (#!) or other executable characteristics before setting this flag. Otherwise, consider making this configurable via an attribute.

            integrity = ctx.attr.remote_file_integrity.get(path, ""),
            block = False,
            # Overlaid files may be shell scripts.
            executable = path.endswith(".sh"),

)
for path, remote_file_urls in ctx.attr.remote_file_urls.items()
}
Expand Down
Loading