1{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
2
3rustPlatform.buildRustPackage rec {
4 pname = "diskus";
5 version = "0.7.0";
6
7 src = fetchFromGitHub {
8 owner = "sharkdp";
9 repo = "diskus";
10 rev = "v${version}";
11 sha256 = "sha256-SKd2CU0F2iR4bSHntu2VKvZyjjf2XJeXJG6XS/fIBMU=";
12 };
13
14 buildInputs = lib.optionals stdenv.isDarwin [ Security ];
15
16 cargoSha256 = "sha256-qNXv6Z9sKl7rol78UTOSRFML/JCGfOJMGOdt49KHD50=";
17
18 meta = with lib; {
19 description = "A minimal, fast alternative to 'du -sh'";
20 homepage = "https://github.com/sharkdp/diskus";
21 license = with licenses; [ asl20 /* or */ mit ];
22 maintainers = [ maintainers.fuerbringer ];
23 platforms = platforms.unix;
24 longDescription = ''
25 diskus is a very simple program that computes the total size of the
26 current directory. It is a parallelized version of du -sh.
27 '';
28 };
29}