Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set xccurrentversion owners #748

Merged
merged 2 commits into from
Jul 28, 2023
Merged
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
19 changes: 13 additions & 6 deletions rules/precompiled_apple_resource_bundle.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -198,20 +198,27 @@ def _precompiled_apple_resource_bundle_impl(ctx):

# See https://github.com/bazel-ios/rules_ios/pull/747 for context
xccurrentversions = [
(None, None, depset([f]))
f
for resource_files in ctx.attr.resources
for f in resource_files.files.to_list()
if f.extension == "xccurrentversion"
]

return [
AppleResourceInfo(
datamodels = xccurrentversions,
datamodels = [
(None, None, depset(xccurrentversions)),
],
unowned_resources = depset(),
owners = depset([
(output_bundle_dir.short_path, ctx.label),
(output_plist.short_path, ctx.label),
]),
owners = depset(
[
(output_bundle_dir.short_path, ctx.label),
(output_plist.short_path, ctx.label),
] + [
(f.short_path, ctx.label)
for f in xccurrentversions
],
),
# This is a list of the resources to propagate without changing further
# In this case the tuple parameters are:
# 1. The final directory the resources should end up in, ex Foo.bundle
Expand Down