mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-11 20:25:32 +03:00
rq: cleanup
This commit is contained in:
parent
9fb5d292ba
commit
05967b7213
1 changed files with 22 additions and 10 deletions
|
@ -2,17 +2,19 @@
|
|||
lib,
|
||||
rustPlatform,
|
||||
fetchFromGitHub,
|
||||
versionCheckHook,
|
||||
nix-update-script,
|
||||
}:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
rustPlatform.buildRustPackage (finalAttrs: {
|
||||
pname = "rq";
|
||||
version = "1.0.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "dflemstr";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-QyYTbMXikLSe3eYJRUALQJxUJjA6VlvaLMwGrxIKfZI=";
|
||||
repo = "rq";
|
||||
tag = "v${finalAttrs.version}";
|
||||
hash = "sha256-QyYTbMXikLSe3eYJRUALQJxUJjA6VlvaLMwGrxIKfZI=";
|
||||
};
|
||||
|
||||
useFetchCargoVendor = true;
|
||||
|
@ -22,24 +24,34 @@ rustPlatform.buildRustPackage rec {
|
|||
# Remove #[deny(warnings)] which is equivalent to -Werror in C.
|
||||
# Prevents build failures when upgrading rustc, which may give more warnings.
|
||||
substituteInPlace src/lib.rs \
|
||||
--replace "#![deny(warnings)]" ""
|
||||
--replace-fail "#![deny(warnings)]" ""
|
||||
|
||||
# build script tries to get version information from git
|
||||
# this fixes the --version output
|
||||
rm build.rs
|
||||
'';
|
||||
|
||||
VERGEN_SEMVER = version;
|
||||
VERGEN_SEMVER = finalAttrs.version;
|
||||
|
||||
meta = with lib; {
|
||||
nativeInstallCheckInputs = [
|
||||
versionCheckHook
|
||||
];
|
||||
versionCheckProgramArg = "--version";
|
||||
doInstallCheck = true;
|
||||
|
||||
passthru = {
|
||||
updateScript = nix-update-script { };
|
||||
};
|
||||
|
||||
meta = {
|
||||
description = "Tool for doing record analysis and transformation";
|
||||
mainProgram = "rq";
|
||||
homepage = "https://github.com/dflemstr/rq";
|
||||
license = with licenses; [ asl20 ];
|
||||
maintainers = with maintainers; [
|
||||
license = with lib.licenses; [ asl20 ];
|
||||
maintainers = with lib.maintainers; [
|
||||
aristid
|
||||
Br1ght0ne
|
||||
figsoda
|
||||
];
|
||||
};
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue