You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary:
The `visibility` config within `fixups.toml` is only supported as a top level config or within `export_sources` so if one wants to modify visibility per crate version, there is currently no way to do that. I considered a couple of design approaches moving forward including making `version` a 1st class citizen by supporting `version` tables:
```toml
[version."=2.2.1"]
overlay = "some_overlay"
visibility = ["//some/..."],
[version."<2.2.1"]
overlay = "other_overlay"
visibility = ["//other/..."],
```
but the above needs a larger redesign we would have to move `version` out of per-platform configs. Since we are to move to a `fixups.bzl` implementation, I'd rather spent the time then and design the `fixups.bzl` spec from the ground up. For now, I went with the least intrusive approach by allowing the top level `visibility` to accept both TOML array and table values. Array values is what is currently supported:
```toml
visibility = ["//some/..."]
```
and table values looks like so:
```
[visibility]
"=2.2.1" = ["//some/..."]
">2.2.1" = ["//other/..."]
```
Reviewed By: dtolnay
Differential Revision: D74600208
fbshipit-source-id: 5265517c87d16d1b7d17c18387b0bbed12531f5f
0 commit comments