From 84e179acb4f269963cbccc8f154be12e71370613 Mon Sep 17 00:00:00 2001 From: Jonas Hahn Date: Sun, 31 Aug 2025 05:04:19 +0200 Subject: [PATCH] Fixed the other two laptops to work --- hosts/nixyos-asus/configuration.nix | 32 ++++++++++++++++++------- hosts/thinix-thinkpad/configuration.nix | 20 ++++++++-------- modules/services/scanning.nix | 11 +++++++++ 3 files changed, 44 insertions(+), 19 deletions(-) create mode 100644 modules/services/scanning.nix diff --git a/hosts/nixyos-asus/configuration.nix b/hosts/nixyos-asus/configuration.nix index b998718..85159df 100644 --- a/hosts/nixyos-asus/configuration.nix +++ b/hosts/nixyos-asus/configuration.nix @@ -1,20 +1,34 @@ -{ ... }: +{ ... }: { - imports = [ + imports = [ ./hardware-configuration.nix - ../../user/users.nix - ../../modules/common.nix + ./../../user/users.nix - ../../modules/hardware/battery.nix - ../../modules/hardware/xremap.nix + ./../../modules/common.nix + + ./../../modules/hardware/xremap.nix + ./../../modules/hardware/battery.nix + + ./../../modules/graphics/workstation.nix + + ./../../modules/services/webdav.nix.nix + ./../../modules/services/scanning.nix.nix ]; networking.hostName = "nixyos"; + batMode = "single"; - networking.networkmanager.wifi.powersave = true; + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; - system.stateVersion = "24.11"; # Did you read the comment? + networking = { + networkmanager = { + wifi.powersave = true; + }; + }; + + # Older machine + system.stateVersion = "24.11"; } - diff --git a/hosts/thinix-thinkpad/configuration.nix b/hosts/thinix-thinkpad/configuration.nix index 82da44d..76b7e42 100644 --- a/hosts/thinix-thinkpad/configuration.nix +++ b/hosts/thinix-thinkpad/configuration.nix @@ -3,33 +3,32 @@ { imports = [ ./hardware-configuration.nix + ./../../user/users.nix ./../../modules/common.nix ./../../modules/hardware/xremap.nix ./../../modules/hardware/battery.nix + + ./../../modules/graphics/workstation.nix + + ./../../modules/services/webdav.nix.nix + ./../../modules/services/scanning.nix.nix ]; networking.hostName = "thinix"; batMode = "double"; + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; + programs.gnupg.agent = { enable = true; pinentryPackage = with pkgs; pinentry-all; enableSSHSupport = true; }; - # Scanning over the network support - hardware.sane.enable = true; - hardware.sane.extraBackends = [ pkgs.sane-airscan ]; - hardware.sane.disabledDefaultBackends = [ "escl" ]; - services.udev.packages = [ pkgs.sane-airscan ]; - services.avahi.enable = true; - services.avahi.nssmdns = true; - - services.davfs2.enable = true; - networking = { networkmanager = { wifi.powersave = true; @@ -43,5 +42,6 @@ } ]; + # Older machine system.stateVersion = "24.11"; } diff --git a/modules/services/scanning.nix b/modules/services/scanning.nix new file mode 100644 index 0000000..b15b9b9 --- /dev/null +++ b/modules/services/scanning.nix @@ -0,0 +1,11 @@ +{ pkgs, ... }: + +{ + # Scanning over the network support + hardware.sane.enable = true; + hardware.sane.extraBackends = [ pkgs.sane-airscan ]; + hardware.sane.disabledDefaultBackends = [ "escl" ]; + services.udev.packages = [ pkgs.sane-airscan ]; + services.avahi.enable = true; + services.avahi.nssmdns = true; +}