1{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl
2, darwin
3}:
4
5with rustPlatform;
6
7buildRustPackage rec {
8 pname = "chit";
9 version = "0.1.15";
10
11 src = fetchFromGitHub {
12 owner = "peterheesterman";
13 repo = pname;
14 rev = version;
15 sha256 = "0iixczy3cad44j2d7zzj8f3lnmp4jwnb0snmwfgiq3vj9wrn28pz";
16 };
17
18 cargoSha256 = "1w25k3bqmmcrhpkw510vbwph0rfmrzi2wby0z2rz1q4k1f9k486m";
19
20 nativeBuildInputs = stdenv.lib.optionals stdenv.isLinux [ pkgconfig ];
21 buildInputs = []
22 ++ stdenv.lib.optionals stdenv.isLinux [ openssl ]
23 ++ stdenv.lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ CoreFoundation CoreServices Security ])
24 ;
25
26 meta = with stdenv.lib; {
27 description = "Crate help in terminal: A tool for looking up details about rust crates without going to crates.io";
28 longDescription = ''
29 Chit helps answer these questions:
30
31 * Who wrote this crate? What else did they write?
32 * What alternatives are there?
33 * How old is this crate?
34 * What versions are there? When did they come out?
35 * What are the downloads over time?
36 * Should i use this crate?
37 * How mature is it?
38 '';
39 homepage = "https://github.com/peterheesterman/chit";
40 license = licenses.mit;
41 maintainers = [ maintainers.lilyball ];
42 };
43}