2017-07-31 02:21:36 +03:00
|
|
|
{ stdenv, fetchFromGitHub, rustPlatform }:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
name = "fd-${version}";
|
2019-02-13 23:45:31 +03:00
|
|
|
version = "7.3.0";
|
2017-07-31 02:21:36 +03:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "sharkdp";
|
|
|
|
repo = "fd";
|
|
|
|
rev = "v${version}";
|
2019-02-13 23:45:31 +03:00
|
|
|
sha256 = "0y4657w1pi4x9nmbv551dj00dyiv935m8ph7jlv00chwy3hrb3yi";
|
2017-07-31 02:21:36 +03:00
|
|
|
};
|
|
|
|
|
2019-05-25 14:03:08 +03:00
|
|
|
cargoSha256 = "1qqlii9693ih7pxl80v515a13jar3yayr5v7pa57x14i9syir10c";
|
2017-07-31 02:21:36 +03:00
|
|
|
|
2017-10-27 00:08:49 +03:00
|
|
|
preFixup = ''
|
2019-02-13 23:45:31 +03:00
|
|
|
install -Dm644 "$src/doc/fd.1" "$out/man/man1/fd.1"
|
2017-11-16 12:58:32 +03:00
|
|
|
|
2019-02-13 23:45:31 +03:00
|
|
|
install -Dm644 target/release/build/fd-find-*/out/fd.bash \
|
|
|
|
"$out/share/bash-completion/completions/fd.bash"
|
|
|
|
install -Dm644 target/release/build/fd-find-*/out/fd.fish \
|
|
|
|
"$out/share/fish/vendor_completions.d/fd.fish"
|
|
|
|
install -Dm644 target/release/build/fd-find-*/out/_fd \
|
|
|
|
"$out/share/zsh/site-functions/_fd"
|
2017-10-27 00:08:49 +03:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2017-07-31 02:21:36 +03:00
|
|
|
description = "A simple, fast and user-friendly alternative to find";
|
|
|
|
longDescription = ''
|
|
|
|
`fd` is a simple, fast and user-friendly alternative to `find`.
|
|
|
|
|
|
|
|
While it does not seek to mirror all of `find`'s powerful functionality,
|
|
|
|
it provides sensible (opinionated) defaults for 80% of the use cases.
|
|
|
|
'';
|
|
|
|
homepage = "https://github.com/sharkdp/fd";
|
2017-10-27 00:08:49 +03:00
|
|
|
license = with licenses; [ asl20 /* or */ mit ];
|
2018-02-10 22:55:03 +03:00
|
|
|
maintainers = with maintainers; [ dywedir ];
|
2017-10-27 00:08:49 +03:00
|
|
|
platforms = platforms.all;
|
2017-07-31 02:21:36 +03:00
|
|
|
};
|
|
|
|
}
|