repgrep: 0.14.3 -> 0.15.0

This commit is contained in:
arthsmn 2023-12-28 18:59:18 -03:00
parent e4c637d0f1
commit 68dcd5fe07

View file

@ -1,4 +1,5 @@
{ lib
, stdenv
, rustPlatform
, fetchFromGitHub
, asciidoctor
@ -9,16 +10,16 @@
rustPlatform.buildRustPackage rec {
pname = "repgrep";
version = "0.14.3";
version = "0.15.0";
src = fetchFromGitHub {
owner = "acheronfail";
repo = "repgrep";
rev = version;
hash = "sha256-33b0dZJY/lnVJGMfAg/faD6PPJIFZsvMZOmKAqCZw8k=";
hash = "sha256-6ba7EJUts0Ni9EA3ENlK+a2FaPo7JohtCyqwR9DdL1E=";
};
cargoHash = "sha256-UMMTdWJ0/M8lN4abTJEVUGtoNp/g49DyW+OASg3TKfg=";
cargoHash = "sha256-XEjKTZ3qaiLWbm2wF+V97u9tGXDq/oTm249ubUE9n94=";
nativeBuildInputs = [
asciidoctor
@ -32,8 +33,13 @@ rustPlatform.buildRustPackage rec {
pushd "$(dirname "$(find -path '**/repgrep-stamp' | head -n 1)")"
installManPage rgr.1
installShellCompletion rgr.{bash,fish} _rgr
popd
'' + lib.optionalString (stdenv.hostPlatform.canExecute stdenv.buildPlatform) ''
# As it can be seen here: https://github.com/acheronfail/repgrep/blob/0.15.0/.github/workflows/release.yml#L206, the completions are just the same as ripgrep
installShellCompletion --cmd rgr \
--bash <(${lib.getExe ripgrep} --generate complete-bash | sed 's/-c rg/-c rgr/') \
--zsh <(${lib.getExe ripgrep} --generate complete-zsh | sed 's/-c rg/-c rgr/') \
--fish <(${lib.getExe ripgrep} --generate complete-fish | sed 's/-c rg/-c rgr/')
'';
meta = with lib; {