du-dust: install man page and completions

This commit is contained in:
Mario Rodas 2023-01-31 18:38:00 +00:00
parent 6913943ebe
commit af1c72c7a4

View File

@ -1,4 +1,4 @@
{ stdenv, lib, fetchFromGitHub, rustPlatform, AppKit }:
{ stdenv, lib, fetchFromGitHub, rustPlatform, AppKit, installShellFiles }:
rustPlatform.buildRustPackage rec {
pname = "du-dust";
@ -18,10 +18,17 @@ rustPlatform.buildRustPackage rec {
cargoHash = "sha256-jtQ/nkD5XMD2rsq550XsRK416wOCR3OuhgGPeuC3jzc=";
nativeBuildInputs = [ installShellFiles ];
buildInputs = lib.optionals stdenv.isDarwin [ AppKit ];
doCheck = false;
postInstall = ''
installManPage man-page/dust.1
installShellCompletion completions/dust.{bash,fish} --zsh completions/_dust
'';
meta = with lib; {
description = "du + rust = dust. Like du but more intuitive";
homepage = "https://github.com/bootandy/dust";