k6: use stdenv.buildPlatform.canExecute

This commit is contained in:
Peder Bergebakken Sundt
2024-10-21 11:34:20 +02:00
parent 2e685bbac1
commit 1ea118d88f

View File

@@ -22,7 +22,7 @@ buildGoModule rec {
$out/bin/k6 version | grep ${version} > /dev/null
'';
postInstall = lib.optionalString (stdenv.hostPlatform == stdenv.buildPlatform) ''
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd k6 \
--bash <($out/bin/k6 completion bash) \
--fish <($out/bin/k6 completion fish) \