From 1ba978f32f716dac793f50c6f0bde451c310dc49 Mon Sep 17 00:00:00 2001
From: Julien Malka <julien@malka.sh>
Date: Mon, 27 Nov 2023 12:13:56 +0100
Subject: [PATCH] switch to out of tree zotero

---
 flake.nix                    | 2 ++
 lib/mkmachine.nix            | 1 +
 machines/enigma/default.nix  | 4 ----
 machines/fischer/default.nix | 2 --
 4 files changed, 3 insertions(+), 6 deletions(-)

diff --git a/flake.nix b/flake.nix
index 4b4d682..f57697d 100644
--- a/flake.nix
+++ b/flake.nix
@@ -85,6 +85,8 @@
     };
 
     buildbot-nix.url = "github:JulienMalka/buildbot-nix";
+
+    zotero-nix.url = "github:camillemndn/zotero-nix";
   };
 
   outputs = { self, nixpkgs, ... }@inputs:
diff --git a/lib/mkmachine.nix b/lib/mkmachine.nix
index 8f1998f..d03dc63 100644
--- a/lib/mkmachine.nix
+++ b/lib/mkmachine.nix
@@ -63,6 +63,7 @@ nixpkgs.lib.nixosSystem {
             keycloak-keywind = prev.pkgs.callPackage ../packages/keycloak-keywind { };
             nix-rfc-92 = inputs.nix-rfc-92.packages.${system}.default;
             bcachefs-tools = prev.unstable.bcachefs-tools;
+            zotero = inputs.zotero.packages.${system}.default;
           })
       ];
     }
diff --git a/machines/enigma/default.nix b/machines/enigma/default.nix
index 8f46b3f..d7ad4ea 100644
--- a/machines/enigma/default.nix
+++ b/machines/enigma/default.nix
@@ -93,10 +93,6 @@
 
   programs.xwayland.enable = true;
 
-  nixpkgs.config.permittedInsecurePackages = [
-    "zotero-6.0.26"
-  ];
-
   time.timeZone = "Europe/Paris";
 
   # Select internationalisation properties.
diff --git a/machines/fischer/default.nix b/machines/fischer/default.nix
index 83fef7d..43606e3 100644
--- a/machines/fischer/default.nix
+++ b/machines/fischer/default.nix
@@ -54,8 +54,6 @@
     extraOptions = [ "--unsupported-gpu" ];
   };
 
-  nixpkgs.config.permittedInsecurePackages = [ "zotero-6.0.27" ];
-
   services.tailscale.enable = true;
   networking.networkmanager.enable =
     true; # Easiest to use and most distros use this by default.