2023-05-24 13:37:59 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, stdenv
|
|
|
|
, darwin
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "dua";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "2.29.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Byron";
|
|
|
|
repo = "dua-cli";
|
|
|
|
rev = "v${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-rO9k1/HOwVJF/QCT2sZy4L0Mv26CiUj9Zafliffj68A=";
|
2020-04-24 23:36:52 +00:00
|
|
|
# Remove unicode file names which leads to different checksums on HFS+
|
|
|
|
# vs. other filesystems because of unicode normalisation.
|
2022-06-16 17:23:12 +00:00
|
|
|
postFetch = ''
|
2020-04-24 23:36:52 +00:00
|
|
|
rm -r $out/tests/fixtures
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
cargoHash = "sha256-qn1QDiYHcygomOFwFEy00wsMykrQ9/84Ed4nAUTlA1k=";
|
2023-05-24 13:37:59 +00:00
|
|
|
|
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [
|
|
|
|
darwin.apple_sdk.frameworks.Foundation
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Tool to conveniently learn about the disk usage of directories";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/Byron/dua-cli";
|
2023-05-24 13:37:59 +00:00
|
|
|
changelog = "https://github.com/Byron/dua-cli/blob/v${version}/CHANGELOG.md";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = with licenses; [ mit ];
|
2023-05-24 13:37:59 +00:00
|
|
|
maintainers = with maintainers; [ figsoda killercup ];
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "dua";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|