-
-
Notifications
You must be signed in to change notification settings - Fork 25
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
Add support for dependency graph #1
Comments
Basic dependency graph support is done, as can be seen in this example BOM. Won't close this issue unless I have a good solution for replacements though. |
The graph provided by |
Go will only include the latest requested version of a module when compiling, which is reflected in the module list obtained by GetModules. This commit makes it so that the module graph reflects that behavior.
As per golang/go#40513, dependencies of replacements are evaluated, but attributed to the replaced module in the module graph. Addressed this by rewiring the all references to the replacement instead. |
Delivered with v0.2.0 ✔ |
CycloneDX supports dependency graphs.
Coincidentally, Go's
go mod graph
command provides a module graph in pretty much the same structure:An MVP implementation could simply take this output, convert
<path>@<version>
expressions to package URLs and be done with it.Will have to figure out how to deal with replacements though. We currently treat replaced modules as ancestors in the replacement component's pedigree. However, the module graph will still reference the replaced module, not the replacement.
The text was updated successfully, but these errors were encountered: