rustyhorde / vergen

Generate cargo instructions at compile time in build scripts for use with the env! or option_env! macros
Apache License 2.0
396 stars 56 forks source link

Consider making the builders infallible #372

Open Veetaha opened 2 months ago

Veetaha commented 2 months ago

Hi, thank you for the awesome crate :heart:

I'd like to propose an improvement to the vergen API. It currently uses derive_builder to generate builders for various config structs. As a replacement, I propose using the bon crate.

Motivation

The problem with the builders generated by derive_builder are the following:

A comparison table between builder crates can be seen on this page


Would you be interested in this change? I understand that this will require a major release, so I understand if you'd like to push back on this, or postpone doing it until any other reasons for the major release arise.

In any case I can submit a PR from my side if you think it's fine to do it.