From 6b9b36b358baad9ce67ebb74c794f75499c6584a Mon Sep 17 00:00:00 2001 From: redyf Date: Fri, 19 Dec 2025 13:03:52 -0300 Subject: [PATCH] yaak: fix version reporting and icon rendering - Patch package.json and tauri.conf.json to ensure the UI reports the correct version instead of "0.0.0". - Add librsvg, gdk-pixbuf, and adwaita-icon-theme to buildInputs to fix missing icons in the UI. - Add wrapGAppsHook3 to nativeBuildInputs to correctly propagate GTK environment variables. --- pkgs/by-name/ya/yaak/package.nix | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/pkgs/by-name/ya/yaak/package.nix b/pkgs/by-name/ya/yaak/package.nix index ccca382348cd..8f0795275211 100644 --- a/pkgs/by-name/ya/yaak/package.nix +++ b/pkgs/by-name/ya/yaak/package.nix @@ -15,6 +15,9 @@ pango, cairo, pixman, + librsvg, + gdk-pixbuf, + adwaita-icon-theme, protobuf, perl, makeWrapper, @@ -23,6 +26,7 @@ lld, wasm-pack, wasm-bindgen-cli_0_2_100, + wrapGAppsHook3, }: rustPlatform.buildRustPackage (finalAttrs: { @@ -57,6 +61,7 @@ rustPlatform.buildRustPackage (finalAttrs: { lld wasm-pack wasm-bindgen-cli_0_2_100 + wrapGAppsHook3 ]; buildInputs = [ @@ -66,6 +71,9 @@ rustPlatform.buildRustPackage (finalAttrs: { pango cairo pixman + librsvg + gdk-pixbuf + adwaita-icon-theme ] ++ lib.optionals stdenv.hostPlatform.isLinux [ webkitgtk_4_1 @@ -76,11 +84,16 @@ rustPlatform.buildRustPackage (finalAttrs: { env.NPM_CONFIG_IGNORE_SCRIPTS = "true"; postPatch = '' + substituteInPlace package.json \ + --replace-fail '"version": "0.0.0"' '"version": "${finalAttrs.version}"' + substituteInPlace src-tauri/tauri.conf.json \ --replace-fail '"0.0.0"' '"${finalAttrs.version}"' + substituteInPlace src-tauri/tauri.commercial.conf.json \ --replace-fail '"createUpdaterArtifacts": "v1Compatible"' '"createUpdaterArtifacts": false' \ --replace-fail '"https://update.yaak.app/check/{{target}}/{{arch}}/{{current_version}}"' '"https://non.existent.domain"' + substituteInPlace package.json \ --replace-fail '"bootstrap:vendor-node": "node scripts/vendor-node.cjs",' "" \ --replace-fail '"bootstrap:vendor-protoc": "node scripts/vendor-protoc.cjs",' "" @@ -128,7 +141,8 @@ rustPlatform.buildRustPackage (finalAttrs: { postFixup = lib.optionalString stdenv.hostPlatform.isLinux '' wrapProgram $out/bin/yaak-app \ --inherit-argv0 \ - --set-default WEBKIT_DISABLE_DMABUF_RENDERER 1 + --set-default WEBKIT_DISABLE_DMABUF_RENDERER 1 \ + --set-default WEBKIT_DISABLE_COMPOSITING_MODE 1 ''; passthru.updateScript = nix-update-script { };