From 2060d14f06cf9e26a93b677d3d7047f3faf4124d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Wed, 6 Dec 2023 12:41:32 -0800 Subject: [PATCH 1/3] bitwarden: 2023.10.1 -> 2023.12.0 Diff: https://github.com/bitwarden/clients/compare/desktop-v2023.10.1...desktop-v2023.12.0 Changelog: https://github.com/bitwarden/clients/releases/tag/desktop-v2023.12.0 --- pkgs/tools/security/bitwarden/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/tools/security/bitwarden/default.nix b/pkgs/tools/security/bitwarden/default.nix index f3c836fd38600..60c428d6fc06e 100644 --- a/pkgs/tools/security/bitwarden/default.nix +++ b/pkgs/tools/security/bitwarden/default.nix @@ -28,13 +28,13 @@ let electron = electron_25; in buildNpmPackage rec { pname = "bitwarden"; - version = "2023.10.1"; + version = "2023.12.0"; src = fetchFromGitHub { owner = "bitwarden"; repo = "clients"; rev = "desktop-v${version}"; - hash = "sha256-cwSIMN40d1ySUSxBl8jXLVndnJJvPnLiTxkYnA3Pqws="; + hash = "sha256-WYhLKV3j3Ktite5u1H4fSku38hCCrMzKoxtjq6aT9yo="; }; patches = [ @@ -49,14 +49,14 @@ in buildNpmPackage rec { makeCacheWritable = true; npmWorkspace = "apps/desktop"; - npmDepsHash = "sha256-KN8C9Y0tfhHVagk+CUMpI/bIRChhzxC9M27HkU4aTEc="; + npmDepsHash = "sha256-bnYpvHO9Pnob+MbrSshv03mSwXCADH/2xw33nLVKMdg="; cargoDeps = rustPlatform.fetchCargoTarball { name = "${pname}-${version}"; inherit patches src; patchFlags = [ "-p4" ]; sourceRoot = "${src.name}/${cargoRoot}"; - hash = "sha256-AmtdmOR3aZJTZiFbkwRXjeTOJdcN40bTmWx4Ss3JNJ8="; + hash = "sha256-pCy3hGhI3mXm4uTOaFMykOzJqK2PC0t0hE8MrJKtA/k="; }; cargoRoot = "apps/desktop/desktop_native"; From 8aeba41ccab46735ed254fede8d9a1a34d2415c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Wed, 6 Dec 2023 12:45:07 -0800 Subject: [PATCH 2/3] bitwarden-cli: 2023.10.0 -> 2023.12.0 Diff: https://github.com/bitwarden/clients/compare/cli-v2023.10.0...cli-v2023.12.0 Changelog: https://github.com/bitwarden/clients/releases/tag/cli-v2023.12.0 --- pkgs/tools/security/bitwarden/cli.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/security/bitwarden/cli.nix b/pkgs/tools/security/bitwarden/cli.nix index dd35294ba34a8..0ff814617429f 100644 --- a/pkgs/tools/security/bitwarden/cli.nix +++ b/pkgs/tools/security/bitwarden/cli.nix @@ -10,18 +10,18 @@ buildNpmPackage rec { pname = "bitwarden-cli"; - version = "2023.10.0"; + version = "2023.12.0"; src = fetchFromGitHub { owner = "bitwarden"; repo = "clients"; rev = "cli-v${version}"; - hash = "sha256-egXToXWfb9XV7JuCRBYJO4p/e+WOwMncPKz0oBgeALQ="; + hash = "sha256-WYhLKV3j3Ktite5u1H4fSku38hCCrMzKoxtjq6aT9yo="; }; nodejs = nodejs_18; - npmDepsHash = "sha256-iO8ZozVl1vOOqowQARnRJWSFUFnau46+dKfcMSkyU3o="; + npmDepsHash = "sha256-bnYpvHO9Pnob+MbrSshv03mSwXCADH/2xw33nLVKMdg="; nativeBuildInputs = [ python3 From 47a92aac1e4159a08ea23284eca0363638b40d39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=BCtz?= Date: Thu, 7 Dec 2023 13:10:29 -0800 Subject: [PATCH 3/3] bitwarden: use electron_26 Upstream uses Electron 25 which is EOL but the app runs fine under Electron 26. --- pkgs/tools/security/bitwarden/default.nix | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/pkgs/tools/security/bitwarden/default.nix b/pkgs/tools/security/bitwarden/default.nix index 60c428d6fc06e..8c0b703a4fa0e 100644 --- a/pkgs/tools/security/bitwarden/default.nix +++ b/pkgs/tools/security/bitwarden/default.nix @@ -3,7 +3,7 @@ , cargo , copyDesktopItems , dbus -, electron_25 +, electron_26 , fetchFromGitHub , fetchpatch2 , glib @@ -25,10 +25,10 @@ let description = "A secure and free password manager for all of your devices"; icon = "bitwarden"; - electron = electron_25; + electron = electron_26; in buildNpmPackage rec { pname = "bitwarden"; - version = "2023.12.0"; + version = "2023.12.0"; # TODO add back Electron version check below src = fetchFromGitHub { owner = "bitwarden"; @@ -82,12 +82,14 @@ in buildNpmPackage rec { libsecret ]; - preBuild = '' + # FIXME add back once upstream moves to Electron >= 26 + # we use electron_26 because electron_25 is EOL + /*preBuild = '' if [[ $(jq --raw-output '.devDependencies.electron' < package.json | grep -E --only-matching '^[0-9]+') != ${lib.escapeShellArg (lib.versions.major electron.version)} ]]; then echo 'ERROR: electron version mismatch' exit 1 fi - ''; + '';*/ postBuild = '' pushd apps/desktop