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

Support polyglot BUILD.bazel ("Google3" layout) #169

Open
eed3si9n opened this issue Dec 6, 2023 · 1 comment · Fixed by #170
Open

Support polyglot BUILD.bazel ("Google3" layout) #169

eed3si9n opened this issue Dec 6, 2023 · 1 comment · Fixed by #170

Comments

@eed3si9n
Copy link
Contributor

eed3si9n commented Dec 6, 2023

problem

In a "Google3" layout, the source files are supposedly organized by their package names without language tags scala/ or distinction of main vs test:

  • com/example/
    • foo/
      • a.proto
      • b.py
      • C.scala

Currently bzl-gen-build does not support Google3-like layout because one run would overwrite the BUILD.bazel file.

proposal

I wonder if we can support this use case if we implemented --append flag, and keep appending targets on the BUILD file.

@eed3si9n
Copy link
Contributor Author

Currently the Google3 layout to colocate "main" and test targets in one package is limited to --no-aggregate-source mode. This works ok for cases like Protobuf, but I think we also want to aggregate by package in languages like Scala and Java, and potentially even Python to reduce the risk of dangling source files (sources that are added to git but not tracked by any target).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant