about summary refs log tree commit diff
path: root/modules/common
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--modules/common/home-manager.nix2
-rw-r--r--modules/common/secrets.nix6
-rw-r--r--modules/common/security.nix21
-rw-r--r--modules/common/shell/default.nix29
-rw-r--r--modules/common/users.nix1
5 files changed, 18 insertions, 41 deletions
diff --git a/modules/common/home-manager.nix b/modules/common/home-manager.nix
index 31a11f6..54e580d 100644
--- a/modules/common/home-manager.nix
+++ b/modules/common/home-manager.nix
@@ -6,7 +6,7 @@
 }:
 {
   imports = [
-    inputs.home-manager.nixosModule
+    inputs.home-manager.nixosModules.home-manager
     (lib.mkAliasOptionModule
       [ "hm" ]
       [
diff --git a/modules/common/secrets.nix b/modules/common/secrets.nix
index 2b8082e..600b128 100644
--- a/modules/common/secrets.nix
+++ b/modules/common/secrets.nix
@@ -21,11 +21,9 @@
   config = {
     age.identityPaths =
       if this.isHeadful then
-        [ "${config.my.home}/.ssh/id_${lib.my.ssh.type}" ]
+        [ "${config.my.home}/.ssh/${this.hostname}_ed25519" ]
       else
-        config.services.openssh.hostKeys
-        |> lib.filter (attr: attr.type == lib.my.ssh.type)
-        |> map (attr: attr.path);
+        config.services.openssh.hostKeys |> lib.filter (x: x.type == "ed25519") |> map (x: x.path);
 
     environment.systemPackages = with pkgs; [
       age
diff --git a/modules/common/security.nix b/modules/common/security.nix
deleted file mode 100644
index acfc9cc..0000000
--- a/modules/common/security.nix
+++ /dev/null
@@ -1,21 +0,0 @@
-_: {
-  security = {
-    sudo.wheelNeedsPassword = false;
-
-    polkit = {
-      enable = true;
-      extraConfig = ''
-        /*
-         * Allow members of the wheel group to execute any actions
-         * without password authentication, similar to "sudo NOPASSWD:".
-         *
-         * https://wiki.archlinux.org/title/Polkit#Bypass_password_prompt
-         */
-        polkit.addRule(function(action, subject) {
-          if (subject.isInGroup('wheel'))
-            return polkit.Result.YES;
-        });
-      '';
-    };
-  };
-}
diff --git a/modules/common/shell/default.nix b/modules/common/shell/default.nix
index 7c6c835..2e81d45 100644
--- a/modules/common/shell/default.nix
+++ b/modules/common/shell/default.nix
@@ -80,16 +80,17 @@ in
                     let
                       pkg =
                         if this.isHeadful then
-                          pkgs.coreutils.overrideAttrs (
-                            _: super: {
-                              patches = (super.patches or [ ]) ++ [
-                                (pkgs.fetchpatch {
-                                  url = "https://raw.githubusercontent.com/jarun/advcpmv/1e2b1c6b74fa0974896bf94604279a3f74b37a63/advcpmv-0.9-9.5.patch";
-                                  hash = "sha256-LRfb4heZlAUKiXl/hC/HgoqeGMxCt8ruBYZUrbzSH+Y=";
-                                })
-                              ];
-                            }
-                          )
+                          pkgs.coreutils
+                        # pkgs.coreutils.overrideAttrs (
+                        #   _: super: {
+                        #     patches = (super.patches or [ ]) ++ [
+                        #       (pkgs.fetchpatch {
+                        #         url = "https://raw.githubusercontent.com/jarun/advcpmv/1e2b1c6b74fa0974896bf94604279a3f74b37a63/advcpmv-0.9-9.5.patch";
+                        #         hash = "sha256-LRfb4heZlAUKiXl/hC/HgoqeGMxCt8ruBYZUrbzSH+Y=";
+                        #       })
+                        #     ];
+                        #   }
+                        # )
                         else
                           pkgs.coreutils;
                     in
@@ -98,6 +99,8 @@ in
                 )
                 (
                   let
+                    # progressBar = lib.optionalString this.isHeadful "--progress-bar";
+
                     mkAlias =
                       {
                         name ? lib.head command,
@@ -107,8 +110,6 @@ in
                         inherit name;
                         value = lib.concatStringsSep " " command;
                       };
-
-                    progressBar = lib.optionalString this.isHeadful "--progress-bar";
                   in
                   [
                     (mkAlias {
@@ -116,14 +117,14 @@ in
                         "cp"
                         "--interactive"
                         "--recursive"
-                        progressBar
+                        # progressBar
                       ];
                     })
                     (mkAlias {
                       command = [
                         "mv"
                         "--interactive"
-                        progressBar
+                        # progressBar
                       ];
                     })
                     (mkAlias {
diff --git a/modules/common/users.nix b/modules/common/users.nix
index ffe6234..c81f2c1 100644
--- a/modules/common/users.nix
+++ b/modules/common/users.nix
@@ -31,7 +31,6 @@ in
         description = lib.my.fullname;
         inherit home;
         inherit (lib.my) hashedPassword;
-        openssh.authorizedKeys.keys = [ lib.my.ssh.key ];
         extraGroups = [ "wheel" ];
       };
     };

Consider giving Nix/NixOS a try! <3