Skip to content

Conversation

@pkwarren
Copy link
Member

Update codegen to generate to the build directory to minimize the code in this project and match other protovalidate projects.

Upgrade to Gradle 8.13.

Update codegen to generate to the build directory to minimize the code
in this project and match other protovalidate projects.

Upgrade to Gradle 8.13.
Copy link
Member

@timostamm timostamm left a comment

Choose a reason for hiding this comment

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

IMO generating to the build directory works well for java (and dotnet).
Where else do we do this? C++?

Copy link
Contributor

@smaye81 smaye81 left a comment

Choose a reason for hiding this comment

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

Nice. Ran this locally and confirmed make works for me.

@pkwarren
Copy link
Member Author

IMO generating to the build directory works well for java (and dotnet). Where else do we do this? C++?

Looks like C++ does. I think for Java this makes the most sense. I'd like to get protobuf upgrades fully automated via dependabot where we can ensure when protobuf-java is upgraded that we also regenerate code on the latest version. Right now that is a manual step:

# When updating, make sure to update versions in the following files to match and regenerate code with 'make generate'.
# - buf.gen.yaml
# - conformance/buf.gen.yaml
# - src/test/resources/proto/buf.gen.imports.yaml
# - src/test/resources/proto/buf.gen.noimports.yaml

@pkwarren pkwarren merged commit b4c8064 into main Apr 16, 2025
4 checks passed
@pkwarren pkwarren deleted the pkw/remove-generated-code branch April 16, 2025 16:03
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 this pull request may close these issues.

4 participants