mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-02 07:31:26 +00:00
zsh-history: make use of installShellCompletions
helper
This commit is contained in:
parent
165b47bfe4
commit
0f132d0f27
@ -1,4 +1,4 @@
|
||||
{ lib, fetchFromGitHub, buildGoPackage }:
|
||||
{ lib, fetchFromGitHub, buildGoPackage, installShellFiles }:
|
||||
|
||||
buildGoPackage rec {
|
||||
pname = "zsh-history";
|
||||
@ -11,13 +11,15 @@ buildGoPackage rec {
|
||||
sha256 = "12dc380zfg3b9k7rcsyzi9dxqh28c4957b3fsx1nxvqvdm3ralm2";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ installShellFiles ];
|
||||
|
||||
goDeps = ./deps.nix;
|
||||
goPackagePath = "github.com/b4b4r07/history";
|
||||
|
||||
postInstall = ''
|
||||
install -d $out/share
|
||||
cp -r $NIX_BUILD_TOP/go/src/${goPackagePath}/misc/* $out/share
|
||||
cp -r $out/share/zsh/completions $out/share/zsh/site-functions
|
||||
installShellCompletion --zsh --name _history $out/share/zsh/completions/_history
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
|
Loading…
Reference in New Issue
Block a user