Skip to content

document cargoLock.lockFileContents#138801

Merged
happysalada merged 4 commits intoNixOS:masterfrom
dermetfan:cargo-lock-restricted
Sep 22, 2021
Merged

document cargoLock.lockFileContents#138801
happysalada merged 4 commits intoNixOS:masterfrom
dermetfan:cargo-lock-restricted

Conversation

@dermetfan
Copy link
Copy Markdown
Member

Motivation for this change

As requested in #137395 (review)

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • Fits CONTRIBUTING.md.

@dermetfan dermetfan requested a review from danieldk September 21, 2021 11:54
@github-actions github-actions bot added 6.topic: rust General-purpose programming language emphasizing performance, type safety, and concurrency. 8.has: documentation This PR adds or changes documentation labels Sep 21, 2021
cargoLock = {
lockFile = ./Cargo.lock;
}
};
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not related but also not worth another PR

@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels Sep 21, 2021
Make it more clear that the return type is a string.

Co-authored-by: figsoda <figsoda@pm.me>
@dermetfan dermetfan changed the title doc: rust: document cargoLock.lockFileContents document cargoLock.lockFileContents Sep 22, 2021
@dermetfan dermetfan changed the title document cargoLock.lockFileContents document cargoLock.lockFileContents Sep 22, 2021
Do not use recursive attribute sets where not needed, it could confuse the reader.
mentioning that `Cargo.lock` cannot be patched in the `patchPhase`

```nix
rustPlatform.buildRustPackage rec {
rustPlatform.buildRustPackage {
Copy link
Copy Markdown
Member Author

@dermetfan dermetfan Sep 22, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rec is not needed here and could confuse the reader. Not really related but let's keep this snippet and the new, very similar one below in sync.

@happysalada
Copy link
Copy Markdown
Contributor

Thank you for this!

@happysalada happysalada merged commit 5b0a311 into NixOS:master Sep 22, 2021
@dermetfan dermetfan deleted the cargo-lock-restricted branch September 22, 2021 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: rust General-purpose programming language emphasizing performance, type safety, and concurrency. 8.has: documentation This PR adds or changes documentation 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants