about summary refs log tree commit diff
path: root/nix/templates/ctf
diff options
context:
space:
mode:
authorEmile <git@emile.space>2024-09-19 10:48:16 +0200
committerEmile <git@emile.space>2024-09-19 10:48:16 +0200
commite833c13c177288b2a7b9168a784e0e6562c025b6 (patch)
tree1661dad1694989e2d83e6c2fca7b5602a61c574b /nix/templates/ctf
parentdcde3882d5460368e3c0499a54330f84a6995d62 (diff)
big format using nixfmt
Diffstat (limited to 'nix/templates/ctf')
-rw-r--r--nix/templates/ctf/flake.nix47
1 files changed, 26 insertions, 21 deletions
diff --git a/nix/templates/ctf/flake.nix b/nix/templates/ctf/flake.nix
index de6e2c1..67f33ca 100644
--- a/nix/templates/ctf/flake.nix
+++ b/nix/templates/ctf/flake.nix
@@ -7,7 +7,8 @@
   };
 
   # Flake outputs
-  outputs = { self, nixpkgs }:
+  outputs =
+    { self, nixpkgs }:
     let
       # Systems supported
       allSystems = [
@@ -20,28 +21,32 @@
       # Helper to provide system-specific attributes
       nameValuePair = name: value: { inherit name value; };
       genAttrs = names: f: builtins.listToAttrs (map (n: nameValuePair n (f n)) names);
-      forAllSystems = f: genAttrs allSystems (system: f {
-        pkgs = import nixpkgs { inherit system; };
-      });
+      forAllSystems = f: genAttrs allSystems (system: f { pkgs = import nixpkgs { inherit system; }; });
     in
     {
       # Development environment output
-      devShells = forAllSystems ({ pkgs }: {
-        default =
-          let
-            python = pkgs.python311; # Use Python 3.11
-          in
-          pkgs.mkShell {
-            packages = with pkgs; [
-              qemu
-            ] ++ [
-              # Python plus helper tools
-              (python.withPackages (ps: with ps; [
-                pwntools
-                pycryptodome
-              ]))
-            ];
-          };
-      });
+      devShells = forAllSystems (
+        { pkgs }:
+        {
+          default =
+            let
+              python = pkgs.python311; # Use Python 3.11
+            in
+            pkgs.mkShell {
+              packages =
+                with pkgs;
+                [ qemu ]
+                ++ [
+                  # Python plus helper tools
+                  (python.withPackages (
+                    ps: with ps; [
+                      pwntools
+                      pycryptodome
+                    ]
+                  ))
+                ];
+            };
+        }
+      );
     };
 }