diff options
| author | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2024-01-03 05:02:50 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-01-03 05:02:50 +0100 |
| commit | fc08cc3eb8852fdae00c4720bd1c11a5218e05b4 (patch) | |
| tree | 8050284f3763100786de39361b88cc2c712557f2 | |
| parent | Merge pull request #278406 from NixOS/backport-278383-to-release-23.11 (diff) | |
| parent | bitwarden: 2023.12.0 -> 2023.12.1 (diff) | |
| download | nixpkgs-fc08cc3eb8852fdae00c4720bd1c11a5218e05b4.tar.gz | |
Merge pull request #278306 from NixOS/backport-278289-to-release-23.11
[Backport release-23.11] bitwarden: fix build; 2023.12.0 -> 2023.12.1
| -rw-r--r-- | pkgs/tools/security/bitwarden/default.nix | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/pkgs/tools/security/bitwarden/default.nix b/pkgs/tools/security/bitwarden/default.nix index c08da90f59b4..f5091a4b084c 100644 --- a/pkgs/tools/security/bitwarden/default.nix +++ b/pkgs/tools/security/bitwarden/default.nix @@ -16,8 +16,10 @@ , moreutils , napi-rs-cli , nodejs_18 +, patchutils_0_4_2 , pkg-config , python3 +, runCommand , rustc , rustPlatform }: @@ -28,13 +30,13 @@ let electron = electron_27; in buildNpmPackage rec { pname = "bitwarden"; - version = "2023.12.0"; + version = "2023.12.1"; src = fetchFromGitHub { owner = "bitwarden"; repo = "clients"; rev = "desktop-v${version}"; - hash = "sha256-WYhLKV3j3Ktite5u1H4fSku38hCCrMzKoxtjq6aT9yo="; + hash = "sha256-kmMEi9jYMPFHIdXyZAkeu8rh+34fEAkFw9uhwUt5k9o="; }; patches = [ @@ -51,14 +53,23 @@ in buildNpmPackage rec { makeCacheWritable = true; npmWorkspace = "apps/desktop"; - npmDepsHash = "sha256-QwG+D0M94HN1AyQlmzKeScZyksiUr5A9igEaox9DYN4="; + npmDepsHash = "sha256-IDqyHiXdMezdPNlZDyRdNzwC3SO5G3gI3h5zoxzzz/g="; cargoDeps = rustPlatform.fetchCargoTarball { name = "${pname}-${version}"; - inherit patches src; + inherit src; + patches = map + (patch: runCommand + (builtins.baseNameOf patch) + { nativeBuildInputs = [ patchutils_0_4_2 ]; } + '' + < ${patch} filterdiff -p1 --include=${lib.escapeShellArg cargoRoot}'/*' > $out + '' + ) + patches; patchFlags = [ "-p4" ]; sourceRoot = "${src.name}/${cargoRoot}"; - hash = "sha256-pCy3hGhI3mXm4uTOaFMykOzJqK2PC0t0hE8MrJKtA/k="; + hash = "sha256-8A33f2q9GoSM8Wh55iqnSfqWIpeRBz+EQT+rmsZsuXs="; }; cargoRoot = "apps/desktop/desktop_native"; |
