4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
42 lines
1.1 KiB
Nix
42 lines
1.1 KiB
Nix
{ stdenv, substituteAll, lib, buildGoPackage, fetchFromGitHub
|
|
, AVFoundation, AudioToolbox, ImageIO, CoreMedia
|
|
, Foundation, CoreGraphics, MediaToolbox
|
|
, gnupg
|
|
}:
|
|
|
|
buildGoPackage rec {
|
|
pname = "keybase";
|
|
version = "5.5.2";
|
|
|
|
goPackagePath = "github.com/keybase/client";
|
|
subPackages = [ "go/kbnm" "go/keybase" ];
|
|
|
|
dontRenameImports = true;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "keybase";
|
|
repo = "client";
|
|
rev = "v${version}";
|
|
sha256 = "01k50mank6cdc7q3yd8m7xi8vmyklsqlmz7hw17a35lqcsjzy9zj";
|
|
};
|
|
|
|
patches = [
|
|
(substituteAll {
|
|
src = ./fix-paths-keybase.patch;
|
|
gpg = "${gnupg}/bin/gpg";
|
|
gpg2 = "${gnupg}/bin/gpg2";
|
|
})
|
|
];
|
|
|
|
buildInputs = stdenv.lib.optionals stdenv.isDarwin [ AVFoundation AudioToolbox ImageIO CoreMedia Foundation CoreGraphics MediaToolbox ];
|
|
buildFlags = [ "-tags production" ];
|
|
|
|
meta = with lib; {
|
|
homepage = "https://www.keybase.io/";
|
|
description = "The Keybase official command-line utility and service";
|
|
platforms = platforms.linux ++ platforms.darwin;
|
|
maintainers = with maintainers; [ avaq carlsverre np rvolosatovs Br1ght0ne ];
|
|
license = licenses.bsd3;
|
|
};
|
|
}
|