mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 14:49:14 +00:00
packages: refactor cargo rust packages
This commit is contained in:
parent
318ca4fbc6
commit
b9639eb49c
4 changed files with 42 additions and 34 deletions
|
|
@ -1,11 +1,13 @@
|
|||
{
|
||||
lib,
|
||||
rustPlatform,
|
||||
fetchFromGitea,
|
||||
}:
|
||||
rustPlatform.buildRustPackage (finalAttrs: {
|
||||
rustPlatform.buildRustPackage (finalAttrs: let
|
||||
cargoToml = fromTOML (builtins.readFile (finalAttrs.src + "/Cargo.toml"));
|
||||
cargoLock = finalAttrs.src + "/Cargo.lock";
|
||||
in {
|
||||
pname = "audio-lint";
|
||||
version = lib.substring 0 8 finalAttrs.src.rev;
|
||||
version = cargoToml.package.version;
|
||||
|
||||
src = fetchFromGitea {
|
||||
domain = "git.confusedcompiler.org";
|
||||
|
|
@ -15,5 +17,5 @@ rustPlatform.buildRustPackage (finalAttrs: {
|
|||
hash = "sha256-h1SnWAh3FPL5GweOXVXXtp+swZApgecYaWjy7rM/J+w=";
|
||||
};
|
||||
|
||||
cargoHash = "sha256-daaNDuxS/mbADCk4X+ZOrzEeu2vrQj1gDJ9y9bMihSk=";
|
||||
cargoLock.lockFile = cargoLock;
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue