1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-06-09 17:46:29 +09:00

git-town: fix cross build (#406782)

This commit is contained in:
Ben Siraphob 2025-05-14 00:10:46 -04:00 committed by GitHub
commit 010ec20008
Signed by: github
GPG key ID: B5690EEEBB952194

View file

@ -1,5 +1,6 @@
{
lib,
stdenv,
buildGoModule,
fetchFromGitHub,
installShellFiles,
@ -64,12 +65,14 @@ buildGoModule rec {
in
[ "-skip=^${builtins.concatStringsSep "$|^" skippedTests}$" ];
postInstall = ''
postInstall =
lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd git-town \
--bash <($out/bin/git-town completions bash) \
--fish <($out/bin/git-town completions fish) \
--zsh <($out/bin/git-town completions zsh)
''
+ ''
wrapProgram $out/bin/git-town --prefix PATH : ${lib.makeBinPath [ git ]}
'';