Robert Schütz
2024-11-22 16:01:59 -08:00
parent 47273151ea
commit 82bb9f42b9
+6 -16
View File
@@ -3,22 +3,22 @@
, buildNpmPackage
, nodejs_20
, fetchFromGitHub
, python3
, cctools
, nix-update-script
, nixosTests
, perl
, xcbuild
}:
buildNpmPackage rec {
pname = "bitwarden-cli";
version = "2024.9.0";
version = "2024.11.0";
src = fetchFromGitHub {
owner = "bitwarden";
repo = "clients";
rev = "cli-v${version}";
hash = "sha256-o5nRG2j73qheDOyeFfSga64D8HbTn1EUrCiN0W+Xn0w=";
hash = "sha256-4QTQgW8k3EMf07Xqs2B+VXQOUPzoOgaNvoC02x4zvu8=";
};
postPatch = ''
@@ -28,12 +28,11 @@ buildNpmPackage rec {
nodejs = nodejs_20;
npmDepsHash = "sha256-L7/frKCNlq0xr6T+aSqyEQ44yrIXwcpdU/djrhCJNNk=";
npmDepsHash = "sha256-YzhCyNMvfXGmgOpl3qWj1Pqd1hY8CJ9QLwQds5ZMnqg=";
nativeBuildInputs = [
(python3.withPackages (ps: with ps; [ setuptools ]))
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
nativeBuildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
cctools
perl
xcbuild.xcrun
];
@@ -44,15 +43,6 @@ buildNpmPackage rec {
npm_config_build_from_source = "true";
};
# node-argon2 builds with LTO, but that causes missing symbols. So disable it
# and rebuild. See https://github.com/ranisalt/node-argon2/pull/415
preConfigure = ''
pushd node_modules/argon2
substituteInPlace binding.gyp --replace-fail '"-flto", ' ""
"$npm_config_node_gyp" rebuild
popd
'';
npmBuildScript = "build:oss:prod";
npmWorkspace = "apps/cli";