Merge pull request #279419 from natsukium/starship/fix

starship: fix aarch64-darwin build
This commit is contained in:
Nick Cao 2024-01-08 11:19:21 -05:00 committed by GitHub
commit a82f082886
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -28,6 +28,11 @@ rustPlatform.buildRustPackage rec {
NIX_LDFLAGS = lib.optionals (stdenv.isDarwin && stdenv.isx86_64) [ "-framework" "AppKit" ];
# tries to access HOME only in aarch64-darwin environment when building mac-notification-sys
preBuild = lib.optionalString (stdenv.isDarwin && stdenv.isAarch64) ''
export HOME=$TMPDIR
'';
postInstall = ''
installShellCompletion --cmd starship \
--bash <($out/bin/starship completions bash) \