Repository navigation
Make both name/version take precedence if in [workspace.metadata.crane] - #1099
Merged
Merged
Conversation
…ves. # Rationale If this metadata section is present, it's specific to nix (and crane), so it is incoherent for the `nix` build to use _different_ values for these in its derived pacakge. Additionally, adding support for `version` is necessary for many rust workspaces where different crates have different versions, and none should be automatically prioritized for the nix derivation.
Owner
|
Thanks for the fix! |
ipetkov
enabled auto-merge (squash)
November 4, 2026 23:52
ipetkov
disabled auto-merge
November 4, 2026 23:56
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
If either
nameorversionare present inCargo.toml's[workspace.metadata.crane]section, these define the nix package metadata. If either is not present, other existing fallback alternatives are consulted.This also changes the implementation of
[workspace.metadata.crane.name]precedence in a way that matches the doc comment, whereas prior to this change the comment and implementation diverged.Motivation
If this metadata section is present, it's specific to nix (and crane), so it is incoherent for the
nixbuild to use different values for these in its derived package.Additionally, adding support for
versionis necessary for many rust workspaces where different crates have different versions, so none of the fallbacks can be coherent.Checklist
docs/API.md(or general documentation) with changesCHANGELOG.md