-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Builder: add option to skip generate #7541
Comments
To build and resolve modules you don't need this binary, you can use a simple |
I agree, but some flags (linking for instance) can be defined in the builder config file which has different owner in my case. The builder provides also out of the box default build configuration that we would like to inherit and follow based on builder evolution. |
I'm also a bit confused: if you don't have the sources, what do you have? Only the manifest? |
As I understood, there are 3 steps in the builder: code generation, module resolution, build In my scenario, the 2 first steps are executed in a 'generate source' step and committed to a git repo (skipping compilation). It's today possible to skip compilation and module resolution, but not code generation. |
I see, thank you for the clarification. While I enjoy seeing this tool being used in different manners than what I originally planned, I wouldn't use it this way myself. Besides, I think the value the tool would provide without its main purpose (generating code) would be too low to justify having this option. On the other hand, I believe it should be relatively easy to implement this solution, as you proved with your PR. |
I came looking for a similar issue and found this one. I would like to support use of the builder within an existing monorepo, meaning to support updating an existing go.mod instead somewhere outside the generated code. See this branch main...jmacd:opentelemetry-collector:jmacd/skip_generate_builder I added one commit on top of the one in #7542 with a second new option related to skipping. The new option
This commit also checks a few invalid configurations. When This allows the builder to generate a build without unnecessarily starting with a fresh set of Go dependencies. Whereas generating a new go.mod every time will result in using the newest version of all unspecified dependencies, using (However, I think this change is somewhat unfinished. There are core collector components that should also have |
This option makes the builder skip generating sources. **Link to tracking Issue:** #7541 **Testing:** Unit tests **Documentation:** as part of the CLI help menu Signed-off-by: Francois JACQUES <[email protected]>
Is your feature request related to a problem? Please describe.
The builder currently offers skipping building and resolving modules. We have a case where we would like to skip generated sources as we need to version it but then resolve modules and build in the CI.
Describe the solution you'd like
Add an option to skip generate.
Describe alternatives you've considered
I did not find any alternative as I cannot hook into the builder lifecycle.
The text was updated successfully, but these errors were encountered: