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

fix: Preserve all manual changes to API_ROOT files for now #82

Merged
merged 1 commit into from
Oct 28, 2021

Conversation

dazuma
Copy link
Member

@dazuma dazuma commented Oct 28, 2021

Currently, build_gen overwrites API_ROOT build files (e.g. google/cloud/library/BUILD.bazel as opposed to google/cloud/library/v1/BUILD.bazel) because we aren't building anything substantial in that directory. That is changing, however: Ruby wrapper libraries are scoped to the API root rather than a service version, and their build rules should be located here.

We will ideally want to expand this tool to generate these new build rules. Unfortunately, it will be a bit difficult, because the settings in the ruby_cloud_gapic_library rule for a Ruby wrapper requires knowledge about the existence and status of the service versions and their corresponding rules. So for now we're just going to write these rules manually (starting with internal cl/402717660). This means we need to disable build_gen's overwriting of these files if they already exist, to prevent the mostly-empty default from clobbering our work. That's the change in this PR. If the file is not already present, the default file will still be created. Later, when we're confident in the rules' stability and our ability to generate them reasonably, we'll update this generator to generate them.

@dazuma dazuma requested a review from a team as a code owner October 28, 2021 22:56
@google-cla google-cla bot added the cla: yes This human has signed the Contributor License Agreement. label Oct 28, 2021
Copy link
Member

@viacheslav-rostovtsev viacheslav-rostovtsev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dazuma dazuma merged commit 80fdf50 into googleapis:main Oct 28, 2021
@dazuma dazuma deleted the pr/root-files branch October 28, 2021 23:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants