Merge pull request #82916 from marsam/fix-gh-darwin
gitAndTools.gh: fix build on darwin
This commit is contained in:
commit
313706328d
@ -30,7 +30,9 @@ let
|
|||||||
|
|
||||||
diff-so-fancy = callPackage ./diff-so-fancy { };
|
diff-so-fancy = callPackage ./diff-so-fancy { };
|
||||||
|
|
||||||
gh = callPackage ./gh { };
|
gh = callPackage ./gh {
|
||||||
|
inherit (darwin.apple_sdk.frameworks) Security;
|
||||||
|
};
|
||||||
|
|
||||||
ghq = callPackage ./ghq { };
|
ghq = callPackage ./ghq { };
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ lib, fetchFromGitHub, buildGoModule, installShellFiles }:
|
{ stdenv, fetchFromGitHub, buildGoModule, installShellFiles, Security }:
|
||||||
|
|
||||||
buildGoModule rec {
|
buildGoModule rec {
|
||||||
pname = "gh";
|
pname = "gh";
|
||||||
@ -20,6 +20,7 @@ buildGoModule rec {
|
|||||||
subPackages = [ "cmd/gh" ];
|
subPackages = [ "cmd/gh" ];
|
||||||
|
|
||||||
nativeBuildInputs = [ installShellFiles ];
|
nativeBuildInputs = [ installShellFiles ];
|
||||||
|
buildInputs = stdenv.lib.optionals stdenv.isDarwin [ Security ];
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
for shell in bash fish zsh; do
|
for shell in bash fish zsh; do
|
||||||
$out/bin/gh completion -s $shell > gh.$shell
|
$out/bin/gh completion -s $shell > gh.$shell
|
||||||
@ -27,7 +28,7 @@ buildGoModule rec {
|
|||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "GitHub CLI tool";
|
description = "GitHub CLI tool";
|
||||||
homepage = "https://cli.github.com/";
|
homepage = "https://cli.github.com/";
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user