nixpkgs/pkgs/development/tools/chit/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

57 lines
1.3 KiB
Nix
Raw Normal View History

{ lib
, rustPlatform
, fetchFromGitHub
, pkg-config
, stdenv
, openssl
2019-05-13 05:49:40 +00:00
, darwin
}:
rustPlatform.buildRustPackage rec {
2019-05-13 05:49:40 +00:00
pname = "chit";
2019-10-19 21:15:19 +00:00
version = "0.1.15";
2019-05-13 05:49:40 +00:00
src = fetchFromGitHub {
owner = "peterheesterman";
repo = pname;
rev = version;
2019-10-19 21:15:19 +00:00
sha256 = "0iixczy3cad44j2d7zzj8f3lnmp4jwnb0snmwfgiq3vj9wrn28pz";
2019-05-13 05:49:40 +00:00
};
cargoLock = {
lockFile = ./Cargo.lock;
};
2019-05-13 05:49:40 +00:00
nativeBuildInputs = lib.optionals stdenv.isLinux [ pkg-config ];
buildInputs = lib.optionals stdenv.isLinux [
openssl
] ++ lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.Security
];
# update Carg.lock to work with openssl 3
postPatch = ''
ln -sf ${./Cargo.lock} Cargo.lock
'';
2019-05-13 05:49:40 +00:00
meta = with lib; {
2019-05-13 05:49:40 +00:00
description = "Crate help in terminal: A tool for looking up details about rust crates without going to crates.io";
mainProgram = "chit";
2019-05-13 05:49:40 +00:00
longDescription = ''
Chit helps answer these questions:
* Who wrote this crate? What else did they write?
* What alternatives are there?
* How old is this crate?
* What versions are there? When did they come out?
* What are the downloads over time?
* Should i use this crate?
* How mature is it?
'';
homepage = "https://github.com/peterheesterman/chit";
2019-05-13 05:49:40 +00:00
license = licenses.mit;
maintainers = with maintainers; [ figsoda lilyball ];
2019-05-13 05:49:40 +00:00
};
}