From 357c8d36d0773ed9e4dfc57f0de7b2da2c41ba72 Mon Sep 17 00:00:00 2001 From: Kate Adkins Date: Sat, 23 Nov 2024 18:42:44 -0700 Subject: [PATCH] hinata: update config, add fprintd --- flake.nix | 3 ++- nixos/configs/nix.nix | 2 +- nixos/configs/syncthing.nix | 1 + nixos/hosts/hinata.nix | 33 +++++++++++++++++++++++++++------ xonsh/includes/nixos.xsh | 3 +++ 5 files changed, 34 insertions(+), 8 deletions(-) diff --git a/flake.nix b/flake.nix index e4520cc..b9587e9 100644 --- a/flake.nix +++ b/flake.nix @@ -319,8 +319,9 @@ modules = linuxOfflineGuiModules [ ./nixos/hosts/hinata.nix - ./nixos/configs/power-saving.nix + ./nixos/configs/vmware.nix ./nixos/configs/cellular.nix + ./nixos/configs/power-saving.nix ]; }; diff --git a/nixos/configs/nix.nix b/nixos/configs/nix.nix index 1d2f358..f72639c 100644 --- a/nixos/configs/nix.nix +++ b/nixos/configs/nix.nix @@ -32,7 +32,7 @@ system = "x86_64-linux"; protocol = "ssh"; - hostName = "trailblazer.kate.ts.polytheon.org"; + hostName = "trailblazer.kate.tailnet.polytheon.org"; sshUser = "deprekated"; sshKey = "/home/deprekated/.ssh/id_ed25519"; diff --git a/nixos/configs/syncthing.nix b/nixos/configs/syncthing.nix index 34cd3f0..f9dd4cd 100644 --- a/nixos/configs/syncthing.nix +++ b/nixos/configs/syncthing.nix @@ -9,6 +9,7 @@ let "design" = { id = "XLTC5OX-3ZU6CYZ-MJ7TAY7-ZAMRIE4-SS2JWFB-FC3RJIO-B3BIQFV-J7U53QK"; }; "trailblazer" = { id = "JASHWW7-AYYTQLN-QZ6OEOX-EZK4GPA-OYW5IZS-5KAIIVR-MMXMCHL-OERDBQ2"; }; "aigis" = { id = "VKRQ6Q4-CCLJR2I-ECOWXRE-TANA2QZ-BJIAPCN-FFVJSB4-GYJNS4R-Z3LLHQ5"; }; + "hinata" = { id = "2SFRG2A-AZ3XPMN-H3RK2Z6-UXPBPIN-DJN7AMN-JBOY23D-EZGFYNR-HRBI2AY"; }; }; in { diff --git a/nixos/hosts/hinata.nix b/nixos/hosts/hinata.nix index 532d9a4..44e9527 100644 --- a/nixos/hosts/hinata.nix +++ b/nixos/hosts/hinata.nix @@ -11,6 +11,25 @@ modulesPath, ... }: +let + # libfprint with patches for the GPD-provided reader + libfprint-gpd = pkgs.libfprint.overrideAttrs (prev: { + version = "git"; + + src = pkgs.fetchFromGitHub { + owner = "ericlinagora"; + repo = "libfprint-CS9711"; + rev = "c242a40fcc51aec5b57d877bdf3edfe8cb4883fd"; + sha256 = "sha256-WFq8sNitwhOOS3eO8V35EMs+FA73pbILRP0JoW/UR80="; + }; + + nativeBuildInputs = prev.nativeBuildInputs ++ (with pkgs; [ + opencv + cmake + doctest + ]); + }); +in { system.stateVersion = "23.11"; @@ -35,7 +54,7 @@ # Niri configuration for our monitors. # home-manager.users.deprekated.programs.niri.settings = { - outputs."eDP-1".scale = 2.0; + outputs."eDP-1".scale = 1.5; }; # Override stylix font sizes. @@ -51,6 +70,13 @@ } ]; + # Fingerprint reader support. + services.fprintd = { + enable = true; + package = pkgs.fprintd.override { libfprint = libfprint-gpd; }; + }; + + # # Hardware config. # @@ -92,9 +118,4 @@ nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; - - hardware.opengl = { - enable = true; - driSupport = true; - }; } diff --git a/xonsh/includes/nixos.xsh b/xonsh/includes/nixos.xsh index 31ac651..e0070d5 100644 --- a/xonsh/includes/nixos.xsh +++ b/xonsh/includes/nixos.xsh @@ -18,6 +18,9 @@ aliases['rebuild'] = 'sudo nixos-rebuild --flake "/home/deprekated/dotfiles?subm # Allow non-free for regular commands. $NIXPKGS_ALLOW_UNFREE=1 +# This is too often necessary. +aliases['unfuck'] = 'sudo nix-store --repair-path' + def _nix_locate(args, stdin=None, silent=False): """ Helper for finding a direct provider of a nix package. """