Skip to content

[Feeature Request] Support aggregation of protos and their dependencies into one Swift module #1456

Open
@Skoti

Description

@Skoti

Motivation

Given one or many proto_library targets with dependencies, one would like to put them all into a single Swift module.

Currently, it is possible only if labels for all proto_library targets and their dependent targets are manually repeated in the protos attribute of the swift_proto_library rule.
However, this creates a maintenance hell, as each time one of the proto_library targets gets modified, the same change needs to be reflected in this swift_proto_library aggregation target, resulting in two sources of truth.

It would be great if this could be done automatically, by only providing the leaf proto_library targets.

Proposed solution

The idea is to create an aspect that collects ProtoInfo transitively and add an attribute that uses it to the swift_proto_library rule.

@AttilaTheFun I'm tagging you as requested :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions