Merge pull request #129214 from kidonng/patch-1
sd: install man page and shell completions
This commit is contained in:
commit
de1039e066
|
@ -1,4 +1,4 @@
|
||||||
{ lib, stdenv, fetchFromGitHub, rustPlatform, Security
|
{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, Security
|
||||||
}:
|
}:
|
||||||
|
|
||||||
rustPlatform.buildRustPackage rec {
|
rustPlatform.buildRustPackage rec {
|
||||||
|
@ -14,8 +14,17 @@ rustPlatform.buildRustPackage rec {
|
||||||
|
|
||||||
cargoSha256 = "1iwgy9zzdxay6hb9pz47jchy03jrsy5csxijlq4i228qhqnvq1lr";
|
cargoSha256 = "1iwgy9zzdxay6hb9pz47jchy03jrsy5csxijlq4i228qhqnvq1lr";
|
||||||
|
|
||||||
|
nativeBuildInputs = [ installShellFiles ];
|
||||||
|
|
||||||
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
|
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
|
||||||
|
|
||||||
|
preFixup = ''
|
||||||
|
installManPage $releaseDir/build/sd-*/out/sd.1
|
||||||
|
|
||||||
|
installShellCompletion $releaseDir/build/sd-*/out/sd.{bash,fish}
|
||||||
|
installShellCompletion --zsh $releaseDir/build/sd-*/out/_sd
|
||||||
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Intuitive find & replace CLI (sed alternative)";
|
description = "Intuitive find & replace CLI (sed alternative)";
|
||||||
homepage = "https://github.com/chmln/sd";
|
homepage = "https://github.com/chmln/sd";
|
||||||
|
|
Loading…
Reference in a new issue