about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Hensing <robert@roberthensing.nl>2024-02-28 22:55:30 +0100
committerRobert Hensing <robert@roberthensing.nl>2024-03-06 22:47:24 +0100
commit88e807a141d2d5e9049083381ec2a9ac9148455a (patch)
treef5dcecb2808e72e2d9d5ee13ba345975a85c50be
parent576be941f8cceed14a6a937a61e42814a553312d (diff)
nixops_unstable_*: Remove unnecessary r fixpoint
-rw-r--r--pkgs/applications/networking/cluster/nixops/default.nix50
1 files changed, 23 insertions, 27 deletions
diff --git a/pkgs/applications/networking/cluster/nixops/default.nix b/pkgs/applications/networking/cluster/nixops/default.nix
index 8bcd0f9db630d..4d61e019a33e9 100644
--- a/pkgs/applications/networking/cluster/nixops/default.nix
+++ b/pkgs/applications/networking/cluster/nixops/default.nix
@@ -46,34 +46,30 @@ let
         selectedPlugins = selector this.availablePlugins;
       });
 
-    rawPackage =
-      let
-        r = this.python.pkgs.toPythonApplication (this.python.pkgs.nixops.overridePythonAttrs (old: {
-          propagatedBuildInputs = old.propagatedBuildInputs ++ this.selectedPlugins;
-
-          # Propagating dependencies leaks them through $PYTHONPATH which causes issues
-          # when used in nix-shell.
-          postFixup = ''
-            rm $out/nix-support/propagated-build-inputs
-          '';
-
-          passthru = old.passthru // {
-            inherit (this) selectedPlugins availablePlugins withPlugins python;
-            tests = old.passthru.tests // {
-              nixos = old.passthru.tests.nixos.passthru.override {
-                nixopsPkg = r;
-              };
-            }
-              # Make sure we also test with a configuration that's been extended with a plugin.
-              // lib.optionalAttrs (this.selectedPlugins == [ ]) {
-              withAPlugin =
-                lib.recurseIntoAttrs
-                  (this.withPlugins (ps: with ps; [ nixops-encrypted-links ])).tests;
-            };
+    rawPackage = this.python.pkgs.toPythonApplication (this.python.pkgs.nixops.overridePythonAttrs (old: {
+      propagatedBuildInputs = old.propagatedBuildInputs ++ this.selectedPlugins;
+
+      # Propagating dependencies leaks them through $PYTHONPATH which causes issues
+      # when used in nix-shell.
+      postFixup = ''
+        rm $out/nix-support/propagated-build-inputs
+      '';
+
+      passthru = old.passthru // {
+        inherit (this) selectedPlugins availablePlugins withPlugins python;
+        tests = old.passthru.tests // {
+          nixos = old.passthru.tests.nixos.passthru.override {
+            nixopsPkg = rawPackage;
           };
-        }));
-      in
-      r;
+        }
+          # Make sure we also test with a configuration that's been extended with a plugin.
+          // lib.optionalAttrs (this.selectedPlugins == [ ]) {
+          withAPlugin =
+            lib.recurseIntoAttrs
+              (this.withPlugins (ps: with ps; [ nixops-encrypted-links ])).tests;
+        };
+      };
+    }));
 
     public = this.rawPackage;
   };