about summary refs log tree commit diff
path: root/pkgs/tools/misc/starship
diff options
context:
space:
mode:
authorTheodore Ni <3806110+tjni@users.noreply.github.com>2022-09-27 01:10:54 -0700
committerTheodore Ni <3806110+tjni@users.noreply.github.com>2022-11-04 17:55:53 -0700
commit7b9bb27e082211b422787489384cbe31c0abf096 (patch)
tree83493e0c90bce2b8c5272610f0b943bc29932951 /pkgs/tools/misc/starship
parent8982f61dd3b58d5520705082069828d87e9fcefc (diff)
starship: reenable default features on darwin
Diffstat (limited to 'pkgs/tools/misc/starship')
-rw-r--r--pkgs/tools/misc/starship/default.nix11
1 files changed, 4 insertions, 7 deletions
diff --git a/pkgs/tools/misc/starship/default.nix b/pkgs/tools/misc/starship/default.nix
index fdee67de119b0..e25ee09af6bf8 100644
--- a/pkgs/tools/misc/starship/default.nix
+++ b/pkgs/tools/misc/starship/default.nix
@@ -3,7 +3,6 @@
 , fetchFromGitHub
 , rustPlatform
 , installShellFiles
-, libiconv
 , cmake
 , fetchpatch
 , nixosTests
@@ -20,16 +19,14 @@ rustPlatform.buildRustPackage rec {
     owner = "starship";
     repo = pname;
     rev = "v${version}";
-    sha256 = "sha256-90mh8C52uD68K5o1LE22gkbL1gy6FyMJTiiN9oV/3DE=";
+    hash = "sha256-90mh8C52uD68K5o1LE22gkbL1gy6FyMJTiiN9oV/3DE=";
   };
 
   nativeBuildInputs = [ installShellFiles cmake ];
 
-  buildInputs = lib.optionals stdenv.isDarwin [ libiconv Security Foundation Cocoa ];
+  buildInputs = lib.optionals stdenv.isDarwin [ Security Foundation Cocoa ];
 
-  buildNoDefaultFeatures = true;
-  # the "notify" feature is currently broken on darwin
-  buildFeatures = if stdenv.isDarwin then [ "battery" ] else [ "default" ];
+  NIX_LDFLAGS = lib.optionals (stdenv.isDarwin && stdenv.isx86_64) [ "-framework" "AppKit" ];
 
   postInstall = ''
     installShellCompletion --cmd starship \
@@ -38,7 +35,7 @@ rustPlatform.buildRustPackage rec {
       --zsh <($out/bin/starship completions zsh)
   '';
 
-  cargoSha256 = "sha256-Q1VY9RyHEsQAWRN/upeG5XJxJfrmzj5FQG6GBGrN0xU=";
+  cargoHash = "sha256-Q1VY9RyHEsQAWRN/upeG5XJxJfrmzj5FQG6GBGrN0xU=";
 
   preCheck = ''
     HOME=$TMPDIR