Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

anytype: fix single instance detection and specify URL in .desktop file

+27 -1
+25
pkgs/by-name/an/anytype/0001-fix-single-instance-detection-when-not-packaged.patch
··· 1 + From 0622b4b5497d8bd923eb0d6dd3f917dfcbda9d53 Mon Sep 17 00:00:00 2001 2 + From: Axel Karjalainen <axel@axka.fi> 3 + Date: Thu, 22 May 2025 22:38:14 +0300 4 + Subject: [PATCH] fix: single instance detection when not packaged 5 + 6 + --- 7 + electron.js | 2 +- 8 + 1 file changed, 1 insertion(+), 1 deletion(-) 9 + 10 + diff --git a/electron.js b/electron.js 11 + index d70f20f..158bb93 100644 12 + --- a/electron.js 13 + +++ b/electron.js 14 + @@ -76,7 +76,7 @@ if (is.development && !port) { 15 + return; 16 + }; 17 + 18 + -if (app.isPackaged && !app.requestSingleInstanceLock()) { 19 + +if (!is.development && !app.requestSingleInstanceLock()) { 20 + Api.exit(mainWindow, '' ,false); 21 + return; 22 + }; 23 + -- 24 + 2.49.0 25 +
+2 -1
pkgs/by-name/an/anytype/package.nix
··· 52 52 53 53 patches = [ 54 54 ./0001-feat-update-Disable-auto-checking-for-updates-and-updating-manually.patch 55 + ./0001-fix-single-instance-detection-when-not-packaged.patch 55 56 ]; 56 57 57 58 buildPhase = '' ··· 101 102 desktopItems = [ 102 103 (makeDesktopItem { 103 104 name = "anytype"; 104 - exec = "anytype"; 105 + exec = "anytype %U"; 105 106 icon = "anytype"; 106 107 desktopName = "Anytype"; 107 108 comment = description;