From f065c1feecbe34e20fd0899ca1b3974022036ba2 Mon Sep 17 00:00:00 2001 From: xmnlz Date: Wed, 29 Apr 2026 01:28:09 +0200 Subject: [PATCH] anytype: fix desktop entry (cherry picked from commit 25b3f18c18a5784245e99660e6052e92d209fcc2) --- .../an/anytype/0003-remove-desktop-entry.patch | 15 +++++++++++++++ pkgs/by-name/an/anytype/package.nix | 1 + 2 files changed, 16 insertions(+) create mode 100644 pkgs/by-name/an/anytype/0003-remove-desktop-entry.patch diff --git a/pkgs/by-name/an/anytype/0003-remove-desktop-entry.patch b/pkgs/by-name/an/anytype/0003-remove-desktop-entry.patch new file mode 100644 index 000000000000..e772bdff71c6 --- /dev/null +++ b/pkgs/by-name/an/anytype/0003-remove-desktop-entry.patch @@ -0,0 +1,15 @@ +diff --git a/electron/js/util.js b/electron/js/util.js +index da18f41ad0..bb07ec9f21 100644 +--- a/electron/js/util.js ++++ b/electron/js/util.js +@@ -314,7 +314,9 @@ class Util { + if (!is.linux) { + return; + }; +- ++ // NixOS: desktop entries are managed by the package, avoid ++ // writing user-local anytype.desktop which goes stale on updates ++ return; + const { execFile } = require('child_process'); + const home = process.env.HOME || ''; + const dataHome = process.env.XDG_DATA_HOME || path.join(home, '.local', 'share'); diff --git a/pkgs/by-name/an/anytype/package.nix b/pkgs/by-name/an/anytype/package.nix index f38501ae555d..5179ed28a139 100644 --- a/pkgs/by-name/an/anytype/package.nix +++ b/pkgs/by-name/an/anytype/package.nix @@ -57,6 +57,7 @@ buildNpmPackage (finalAttrs: { patches = [ ./0001-feat-update-Disable-auto-checking-for-updates-and-updating-manually.patch ./0002-remove-grpc-devtools.patch + ./0003-remove-desktop-entry.patch ]; buildPhase = ''