Skip to content

Commit

Permalink
feat: install autogen completions through derivation
Browse files Browse the repository at this point in the history
Signed-off-by: Christina Sørensen <[email protected]>
  • Loading branch information
cafkafk committed Jan 10, 2025
1 parent 4e83869 commit 3e80188
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,16 @@ pkgs.buildGoModule rec {
"-X main.assetRoot=${placeholder "lib"}"
];

nativeBuildInputs = [ pkgs.installShellFiles ];

vendorHash = "sha256-Mi0SdvmYao6rLt8+bFcUv2AjHkJTLP85zGka1/cCPzQ=";

postInstall = ''
mkdir -p $lib
cp -v ./data/*.nix $lib
installShellCompletion --cmd morph \
--bash <($out/bin/morph --completion-script-bash) \
--zsh <($out/bin/morph --completion-script-zsh)
'';

outputs = [
Expand Down

0 comments on commit 3e80188

Please sign in to comment.