-
Notifications
You must be signed in to change notification settings - Fork 426
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
Prost Crate Naming Conventions #2889
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Wanted to start a discussion around the current naming conventions in the prost rules provided by rules_rust.
The prost rules set the crate name to the name of the proto_library that is being compiled.
This approach is very prone to clashes e.g. the following folder structure:
In this folder structure the common way to name the proto_library target would be models_proto (Which is the convention that gazelle uses) but that causes issues if there is a consumer that needs both service1/models and service2/models .
I think it makes sense to change the naming conventions or make them configurable since this is a very likely issue when you have a repo with a large protobuf codebase.
Options:
src_protobuf_service1_models_models_proto
andsrc_protobuf_service2_models_models_proto
crate_naming_convention
which acceptsproto_name
andpackage_name
whereproto_name
would keep the current convention butpackage_name
would include the package path in the crate nameThe text was updated successfully, but these errors were encountered: