bazelbuild / bazelbuild/rules_pkg

Try to derive default file mode from input types

Open
#302 2 comments 0 reactions 0 assignees View on GitHub
P3
Dominant language
Starlark
Stars
253
Forks
221
Avg merge
10h 33m
Merged PRs (30d)
1

Description

The current mechanism for setting file modes in `pkg_files` is ad-hoc and requires human intervention to set permissions, even when it's relatively obvious what they're supposed to be: runnable binaries should be runnable, libraries shouldn't.

Investigate mechanisms for determining how we might derive this information. The most likely source of this information is the provider interfaces.

---

That's a good point, however I don't think we're quite there. We'd have to do some introspection magic in `pkg_files` to identify the nature of the dependent rules. Providers? Rule names? This will need to be investigated. At first brush, this feels like it'll be hard to get right.

I feel that this can be postponed to a later task. I'll make a ticket for it.

_Originally posted by @nacl in https://github.com/bazelbuild/rules_pkg/pull/290#discussion_r582332072_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.