@rules_runfiles_group//runfiles_group:lib.bzl
Public API for runfiles group library functions.
Functions & Macros
lib.group_namesReturns the list of group names in a RunfilesGroupInfo instance.
Parameters
*runfiles_group_info |
lib.ordered_groupsParameters
*runfiles_group_info | |
runfiles_group_selection_info | Default: None |
lib.transform_groupsParameters
*runfiles_group_info | |
runfiles_transform_info | Default: None |
@rules_runfiles_group//runfiles_group:providers.bzl
Public API for runfiles group providers.
Providers
RunfilesGroupInfoInformation about grouped runfiles.
Each field in this provider is a depset of File objects, representing a category of runfiles.
Merging all depsets from all fields should yield the same set (or a superset) of files as DefaultInfo.default_runfiles.
This provider functions similarly to OutputGroupInfo, but its presence in the output of a rule indicates that it can be used instead of DefaultInfo.default_runfiles.
It categorizes the runfiles of a target into different groups, allowing for more fine-grained control over which runfiles are used in different contexts.
RunfilesGroupSelectionInfoInformation about filtering and ordering groups of runfiles.
Fields
predicate | A starlark function that takes a single string (group name). |
compare | A starlark function that takes two strings as input (group names) |
group_names | A list of group names defining the desired order. |
extra_group_treatment | How to treat groups not in group_names. One of "exclude", "prepend", or "append". |
RunfilesGroupTransformInfoInformation about how to transform a RunfilesGroupInfo by merging groups.
Fields
transform | A starlark function that takes a RunfilesGroupInfo and returns a new RunfilesGroupInfo. |
merge_groups | A dict mapping output group name (string) to a list of source group names (list of string). |
unmatched_group_treatment | How to treat groups not listed in any merge_groups value. |
default_group_name | The name of the group that unmatched groups are merged into. |
@rules_runfiles_group//runfiles_group:runfiles_group_analysis_test.bzl
Public API for runfiles_group_analysis_test.
Rules
runfiles_group_analysis_testChecks that RunfilesGroupInfo is well formed by comparing the runfiles of the executable (DefaultInfo.default_runfiles.files)
with the union of all runfiles from RunfilesGroupInfo.
Additionally, it can warn about files appearing in multiple groups (overlapping).
| Attribute | Type | Description |
|---|---|---|
*name | name | A unique name for this target. |
*binaries | list of labels | List of *_binary targets to test. |
overlapping_group_behavior | string | How to handle overlapping groups (the same file being present in more than one group). Default: "warn" |