Compare commits

...

4 Commits

18 changed files with 152 additions and 306 deletions

View File

@ -13,13 +13,15 @@ rec {
pictures = "${dir.home}/Pictures";
};
hostname = "nixos";
hostname = "thinkpad";
keymaps = {
layout = "gb,no";
options = "grp:alt_shift_toggle"; # Toggle using ALT + SHIFT
};
monitor1 = ""; # Empty matches all
username = "martin";
# This value determines the NixOS release from which the default

View File

@ -39,6 +39,7 @@ in
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
brightnessctl
wget
xdg-utils
xdg-desktop-portal

280
flake.lock generated
View File

@ -46,20 +46,14 @@
},
"catppuccin": {
"inputs": {
"catppuccin-v1_1": "catppuccin-v1_1",
"catppuccin-v1_2": "catppuccin-v1_2",
"home-manager": "home-manager",
"home-manager-stable": "home-manager-stable",
"nixpkgs": "nixpkgs",
"nixpkgs-stable": "nixpkgs-stable",
"nuscht-search": "nuscht-search"
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1736957255,
"narHash": "sha256-qZZ/K5XheRMjCNYgle90QESuys0PIFJNPJJswMJ0GEA=",
"lastModified": 1739094937,
"narHash": "sha256-LemSQ5AZHwl4ZVlirdpAytDWgS96OZsct7Akx/REdGA=",
"owner": "catppuccin",
"repo": "nix",
"rev": "f06fcadf9a61b6581b392e72f230fa6783fe36e4",
"rev": "aee0cec463e62702751adaeb9f4fc00f2f72879b",
"type": "github"
},
"original": {
@ -68,34 +62,6 @@
"type": "github"
}
},
"catppuccin-v1_1": {
"locked": {
"lastModified": 1734055249,
"narHash": "sha256-pCWJgwo77KD7EJpwynwKrWPZ//dwypHq2TfdzZWqK68=",
"rev": "7221d6ca17ac36ed20588e1c3a80177ac5843fa7",
"revCount": 326,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/catppuccin/nix/1.1.1/0193bdc0-b045-7eed-bbec-95611a8ecdf5/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/catppuccin/nix/1.1.%2A.tar.gz"
}
},
"catppuccin-v1_2": {
"locked": {
"lastModified": 1734734291,
"narHash": "sha256-CFX4diEQHKvZYjnhf7TLg20m3ge1O4vqgplsk/Kuaek=",
"rev": "1e4c3803b8da874ff75224ec8512cb173036bbd8",
"revCount": 344,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/catppuccin/nix/1.2.1/0193e646-1107-7f69-a402-f2a3988ecf1d/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/catppuccin/nix/1.2.%2A.tar.gz"
}
},
"devshell": {
"inputs": {
"nixpkgs": [
@ -119,34 +85,18 @@
},
"flake-compat": {
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"revCount": 57,
"lastModified": 1733328505,
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
"revCount": 69,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz"
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.1.0/01948eb7-9cba-704f-bbf3-3fa956735b52/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz"
}
},
"flake-compat_2": {
"flake": false,
"locked": {
"lastModified": 1733328505,
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": {
"inputs": {
"nixpkgs-lib": [
@ -155,11 +105,11 @@
]
},
"locked": {
"lastModified": 1736143030,
"narHash": "sha256-+hu54pAoLDEZT9pjHlqL9DNzWz0NbUn8NEAHP7PQPzU=",
"lastModified": 1738453229,
"narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "b905f6fc23a9051a6e1b741e1438dbfc0634c6de",
"rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
"type": "github"
},
"original": {
@ -186,24 +136,6 @@
"type": "github"
}
},
"flake-utils_2": {
"inputs": {
"systems": "systems_2"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"git-hooks": {
"inputs": {
"flake-compat": [
@ -217,11 +149,11 @@
]
},
"locked": {
"lastModified": 1735882644,
"narHash": "sha256-3FZAG+pGt3OElQjesCAWeMkQ7C/nB1oTHLRQ8ceP110=",
"lastModified": 1737465171,
"narHash": "sha256-R10v2hoJRLq8jcL4syVFag7nIGE7m13qO48wRIukWNg=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "a5a961387e75ae44cc20f0a57ae463da5e959656",
"rev": "9364dc02281ce2d37a1f55b6e51f7c0f65a75f17",
"type": "github"
},
"original": {
@ -255,31 +187,9 @@
"home-manager": {
"inputs": {
"nixpkgs": [
"catppuccin",
"nixpkgs"
]
},
"locked": {
"lastModified": 1736508663,
"narHash": "sha256-ZOaGwa+WnB7Zn3YXimqjmIugAnHePdXCmNu+AHkq808=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "2532b500c3ed2b8940e831039dcec5a5ea093afc",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"home-manager-stable": {
"inputs": {
"nixpkgs": [
"catppuccin",
"nixpkgs-stable"
]
},
"locked": {
"lastModified": 1736373539,
"narHash": "sha256-dinzAqCjenWDxuy+MqUQq0I4zUSfaCvN9rzuCmgMZJY=",
@ -296,27 +206,6 @@
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1736373539,
"narHash": "sha256-dinzAqCjenWDxuy+MqUQq0I4zUSfaCvN9rzuCmgMZJY=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "bd65bc3cde04c16755955630b344bc9e35272c56",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "release-24.11",
"repo": "home-manager",
"type": "github"
}
},
"home-manager_3": {
"inputs": {
"nixpkgs": [
"nixvim",
@ -324,11 +213,11 @@
]
},
"locked": {
"lastModified": 1736508663,
"narHash": "sha256-ZOaGwa+WnB7Zn3YXimqjmIugAnHePdXCmNu+AHkq808=",
"lastModified": 1738878603,
"narHash": "sha256-fmhq8B3MvQLawLbMO+LWLcdC2ftLMmwSk+P29icJ3tE=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "2532b500c3ed2b8940e831039dcec5a5ea093afc",
"rev": "433799271274c9f2ab520a49527ebfe2992dcfbd",
"type": "github"
},
"original": {
@ -345,11 +234,11 @@
]
},
"locked": {
"lastModified": 1737011541,
"narHash": "sha256-YAT1VozLQ29V56EvEzJQswBOCLZDqn/gTU05mf+UFts=",
"lastModified": 1739002652,
"narHash": "sha256-W83O9ASWUFaDAFY7H9vvW/Gm9PN5Lkh0McYW3bA/6aU=",
"owner": "Jas-SinghFSU",
"repo": "HyprPanel",
"rev": "88609f7e4c244326face34cb992a79053f2c7810",
"rev": "0d5f80ff5cd525b8f27adfb84cef67d90e3d7f10",
"type": "github"
},
"original": {
@ -359,34 +248,6 @@
}
},
"ixx": {
"inputs": {
"flake-utils": [
"catppuccin",
"nuscht-search",
"flake-utils"
],
"nixpkgs": [
"catppuccin",
"nuscht-search",
"nixpkgs"
]
},
"locked": {
"lastModified": 1729958008,
"narHash": "sha256-EiOq8jF4Z/zQe0QYVc3+qSKxRK//CFHMB84aYrYGwEs=",
"owner": "NuschtOS",
"repo": "ixx",
"rev": "9fd01aad037f345350eab2cd45e1946cc66da4eb",
"type": "github"
},
"original": {
"owner": "NuschtOS",
"ref": "v0.0.6",
"repo": "ixx",
"type": "github"
}
},
"ixx_2": {
"inputs": {
"flake-utils": [
"nixvim",
@ -422,11 +283,11 @@
]
},
"locked": {
"lastModified": 1736370755,
"narHash": "sha256-iWcjToBpx4PUd74uqvIGAfqqVfyrvRLRauC/SxEKIF0=",
"lastModified": 1738743987,
"narHash": "sha256-O3bnAfsObto6l2tQOmQlrO6Z2kD6yKwOWfs7pA0CpOc=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "57733bd1dc81900e13438e5b4439239f1b29db0e",
"rev": "ae406c04577ff9a64087018c79b4fdc02468c87c",
"type": "github"
},
"original": {
@ -451,29 +312,13 @@
"type": "github"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1736061677,
"narHash": "sha256-DjkQPnkAfd7eB522PwnkGhOMuT9QVCZspDpJJYyOj60=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "cbd8ec4de4469333c82ff40d057350c30e9f7d36",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-24.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1736883708,
"narHash": "sha256-uQ+NQ0/xYU0N1CnXsa2zghgNaOPxWpMJXSUJJ9W7140=",
"lastModified": 1739020877,
"narHash": "sha256-mIvECo/NNdJJ/bXjNqIh8yeoSjVLAuDuTUzAo7dzs8Y=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "eb62e6aa39ea67e0b8018ba8ea077efe65807dc8",
"rev": "a79cfe0ebd24952b580b1cf08cd906354996d547",
"type": "github"
},
"original": {
@ -485,11 +330,11 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1736916166,
"narHash": "sha256-puPDoVKxkuNmYIGMpMQiK8bEjaACcCksolsG36gdaNQ=",
"lastModified": 1738843498,
"narHash": "sha256-7x+Q4xgFj9UxZZO9aUDCR8h4vyYut4zPUvfj3i+jBHE=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "e24b4c09e963677b1beea49d411cd315a024ad3a",
"rev": "f5a32fa27df91dfc4b762671a0e0a859a8a0058f",
"type": "github"
},
"original": {
@ -521,7 +366,7 @@
"flake-compat": "flake-compat",
"flake-parts": "flake-parts",
"git-hooks": "git-hooks",
"home-manager": "home-manager_3",
"home-manager": "home-manager_2",
"nix-darwin": "nix-darwin",
"nixpkgs": [
"nixpkgs-unstable"
@ -530,11 +375,11 @@
"treefmt-nix": "treefmt-nix"
},
"locked": {
"lastModified": 1736964246,
"narHash": "sha256-gb3ujURRlI/D5Jc8PUDOpJr8RyrTwnDDIDtnQK4upso=",
"lastModified": 1738966895,
"narHash": "sha256-OXOh35rTEnFSO4vj/SDMIlDvFPGW0ba1XhZkfx+AlL0=",
"owner": "nix-community",
"repo": "nixvim",
"rev": "5b068e7f8f2b6beaa1fafe0c8b3604b63bcccc2d",
"rev": "e7f20a602f6e08a70045f36c531bc44ba1baed07",
"type": "github"
},
"original": {
@ -543,44 +388,21 @@
"type": "github"
}
},
"nuscht-search": {
"inputs": {
"flake-utils": "flake-utils",
"ixx": "ixx",
"nixpkgs": [
"catppuccin",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735854821,
"narHash": "sha256-Iv59gMDZajNfezTO0Fw6LHE7uKAShxbvMidmZREit7c=",
"owner": "NuschtOS",
"repo": "search",
"rev": "836908e3bddd837ae0f13e215dd48767aee355f0",
"type": "github"
},
"original": {
"owner": "NuschtOS",
"repo": "search",
"type": "github"
}
},
"nuschtosSearch": {
"inputs": {
"flake-utils": "flake-utils_2",
"ixx": "ixx_2",
"flake-utils": "flake-utils",
"ixx": "ixx",
"nixpkgs": [
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1735854821,
"narHash": "sha256-Iv59gMDZajNfezTO0Fw6LHE7uKAShxbvMidmZREit7c=",
"lastModified": 1738508923,
"narHash": "sha256-4DaDrQDAIxlWhTjH6h/+xfG05jt3qDZrZE/7zDLQaS4=",
"owner": "NuschtOS",
"repo": "search",
"rev": "836908e3bddd837ae0f13e215dd48767aee355f0",
"rev": "86e2038290859006e05ca7201425ea5b5de4aecb",
"type": "github"
},
"original": {
@ -592,7 +414,7 @@
"root": {
"inputs": {
"catppuccin": "catppuccin",
"home-manager": "home-manager_2",
"home-manager": "home-manager",
"hyprpanel": "hyprpanel",
"nixpkgs": "nixpkgs_2",
"nixpkgs-unstable": "nixpkgs-unstable",
@ -603,17 +425,17 @@
},
"spicetify-nix": {
"inputs": {
"flake-compat": "flake-compat_2",
"nixpkgs": [
"nixpkgs"
]
],
"systems": "systems_2"
},
"locked": {
"lastModified": 1737000920,
"narHash": "sha256-o3dtkMm7M/CPCZ0G3MsK3Mv+KqcJEvP4wYR2iLrpPrs=",
"lastModified": 1739074574,
"narHash": "sha256-dLfT4/nIU3RzMHk7I5UigRehSWzq7wGkZxwuQdflO6s=",
"owner": "Gerg-L",
"repo": "spicetify-nix",
"rev": "cd004cdd2af21f7840a28566cd5e32ca71b73aa7",
"rev": "366191fe8e9375d280e9a6b0ed9823468b49f6e7",
"type": "github"
},
"original": {
@ -660,11 +482,11 @@
]
},
"locked": {
"lastModified": 1736154270,
"narHash": "sha256-p2r8xhQZ3TYIEKBoiEhllKWQqWNJNoT9v64Vmg4q8Zw=",
"lastModified": 1738680491,
"narHash": "sha256-8X7tR3kFGkE7WEF5EXVkt4apgaN85oHZdoTGutCFs6I=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "13c913f5deb3a5c08bb810efd89dc8cb24dd968b",
"rev": "64dbb922d51a42c0ced6a7668ca008dded61c483",
"type": "github"
},
"original": {
@ -678,11 +500,11 @@
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1736997529,
"narHash": "sha256-eyZXz3aphVJ8mMZ5KivtnYS+5vhNxVjWGlBJM0DMqlE=",
"lastModified": 1739071251,
"narHash": "sha256-Kj4grI7YpHk2RIsy73Dwg7ikDn94MI7zKrWN0BXrvJI=",
"owner": "0xc000022070",
"repo": "zen-browser-flake",
"rev": "96be5663cc2ef52e8815c90f7abf3363be3950c2",
"rev": "410d6e9a8ba0edd163d0828a4cda1b1f267f2e1a",
"type": "github"
},
"original": {

View File

@ -37,16 +37,17 @@
}:
let
system = "x86_64-linux";
hostname = "thinkpad";
inherit (self) outputs;
common = import ./common.nix;
in
{
defaultPackage.${system} = home-manager.defaultPackage.${system};
defaultPackages.${system} = home-manager.defaultPackage.${system};
# Adds the nix fmt command to format nix files
formatter.${system} = nixpkgs.legacyPackages.${system}.nixfmt-rfc-style;
nixosConfigurations.nixos = nixpkgs.lib.nixosSystem {
nixosConfigurations.${hostname} = nixpkgs.lib.nixosSystem {
system = system;
specialArgs = { inherit outputs inputs; }; # Pass args to modules
modules = [

View File

@ -9,6 +9,11 @@
s = "status";
};
signing = {
signByDefault = true;
key = "848D71DE0590C199";
};
extraConfig = {
push.autoSetupRemote = true;
safe.directory = "/etc/nixos";

View File

@ -5,6 +5,7 @@ let
suspendAfter = 7200;
in
{
wayland.windowManager.hyprland.settings.exec-once = [ "hypridle" ];
services.hypridle = {
enable = true;
settings = {

View File

@ -39,6 +39,7 @@ in
"network"
"systray"
"clock"
"battery"
"notifications"
];
};

View File

@ -1,6 +1,9 @@
# Wallpapers
{ pkgs, ... }:
let
common = import ../../common.nix;
in
{
home.packages = with pkgs; [
hyprpaper
@ -12,7 +15,6 @@
let
wallpaperDir = ../../wallpapers;
monitor1 = "${wallpaperDir}/nixos_waves.png";
monitor2 = "${wallpaperDir}/ekg_v2.png";
in
{
ipc = "on";
@ -21,12 +23,10 @@
preload = [
monitor1
monitor2
];
wallpaper = [
"DP-1,${monitor1}"
"DP-3,${monitor2}"
"${common.monitor1},${monitor1}"
];
};
};

View File

@ -7,17 +7,15 @@ in
{
wayland.windowManager.hyprland.settings = {
monitor = [
"DP-1, 3440x1440@175, 0x0, 1"
"DP-3, 3840x2160@60, 3440x0, 1.5, transform, 1"
"${common.monitor1}, 1920x1080@60.05, 0x0, 1"
];
# Autostart
exec-once = [
app.browser
app.terminal
"hypridle"
"systemctl --user start hyprpolkitagent"
"waypaper --restore"
"hyprsunset -t 5000" # Set blue light filter
];
env = [
@ -107,11 +105,16 @@ in
kb_layout = common.keymaps.layout;
kb_options = common.keymaps.options;
follow_mouse = 1;
sensitivity = 0; # -1.0 - 1.0, 0 means no modification.
touchpad.natural_scroll = false;
sensitivity = 0.4; # -1.0 - 1.0, 0 means no modification.
touchpad.natural_scroll = true;
};
gestures.workspace_swipe = false;
gestures = {
workspace_swipe = true;
workspace_swipe_distance = 150;
workspace_swipe_min_speed_to_force = 0;
workspace_swipe_cancel_ratio = 0.5;
};
device = {
name = "logitech-g502-hero-gaming-mouse";

View File

@ -15,19 +15,19 @@
"custom/notification",
"tray",
"custom/lock",
"custom/power"
"custom/power",
],
"hyprland/workspaces": {
"disable-scroll": false,
"sort-by-name": true,
"format": " {id} "
"format": " {id} ",
},
"hyprland/window": {
"format": "{initialTitle}"
"format": "{initialTitle}",
},
"tray": {
"icon-size": 21,
"spacing": 10
"spacing": 10,
},
// TODO better music module
"custom/music": {
@ -37,7 +37,7 @@
"tooltip": false,
"exec": "playerctl metadata --format='{{ title }}'",
"on-click": "playerctl play-pause",
"max-length": 50
"max-length": 50,
},
"clock": {
"timezone": "Europe/Oslo",
@ -51,39 +51,39 @@
"days": "<span color='#ecc6d9'><b>{}</b></span>",
"weeks": "<span color='#99ffdd'><b>W{}</b></span>",
"weekdays": "<span color='#ffcc66'><b>{}</b></span>",
"today": "<span color='#ff6699'><b><u>{}</u></b></span>"
}
}
"today": "<span color='#ff6699'><b><u>{}</u></b></span>",
},
},
},
"backlight": {
"device": "intel_backlight",
"format": "{icon}",
"format-icons": ["", "", "", "", "", "", "", "", ""]
"format-icons": ["", "", "", "", "", "", "", "", ""],
},
"wireplumber": {
// "scroll-step": 1, // %, can be a float
"format": "{icon} {volume}%",
"format-muted": " ",
"format-icons": {
"default": ["", " ", " "]
"default": ["", " ", " "],
},
"on-click": "pavucontrol"
"on-click": "pavucontrol",
},
"hyprland/language": {
"format-en": "EN",
"format-no": "NO",
"keyboard-name": "logitech-logitech-g710-keyboard",
"on-click": "hyprctl switchxkblayout logitech-logitech-g710-keyboard next"
"on-click": "hyprctl switchxkblayout logitech-logitech-g710-keyboard next",
},
"custom/lock": {
"tooltip": false,
"on-click": "sh -c '(sleep 0.5s; hyprlock)'",
"format": ""
"format": "",
},
"custom/power": {
"tooltip": false,
"on-click": "wlogout &",
"format": " "
"format": " ",
},
"custom/notification": {
"tooltip": false,
@ -96,13 +96,13 @@
"inhibited-notification": "<span foreground='#f38ba8'><sup></sup></span>",
"inhibited-none": "",
"dnd-inhibited-notification": "<span foreground='#f38ba8'><sup></sup></span>",
"dnd-inhibited-none": ""
"dnd-inhibited-none": "",
},
"return-type": "json",
"exec-if": "which swaync-client",
"exec": "swaync-client -swb",
"on-click": "swaync-client -t -sw",
"on-click-right": "swaync-client -d -sw",
"escape": true
}
"escape": true,
},
}

3
modules/battery.nix Normal file
View File

@ -0,0 +1,3 @@
{
services.upower.enable = true;
}

View File

@ -1,5 +1,6 @@
{
imports = [
./battery.nix
./development.nix
./fonts.nix
./gnome

View File

@ -36,6 +36,5 @@
services.ollama = {
enable = true;
acceleration = "cuda";
};
}

View File

@ -1,7 +1,5 @@
{
imports = [
./nvidia.nix
];
imports = [ ];
# Enable OpenGL
hardware.graphics.enable = true;

View File

@ -1,28 +0,0 @@
{ pkgs, ... }:
{
boot.kernelParams = [ "nvidia.NVreg_PreserveVideoMemoryAllocations=1" ];
# For hardware acceleration
environment.sessionVariables.LIBVA_DRIVER_NAME = "nvidia";
hardware = {
graphics.extraPackages = with pkgs; [
# Used for hardware-acceleration
nvidia-vaapi-driver
];
nvidia = {
# Required
modesetting.enable = true;
# Use closed-source drivers
open = false;
# Enable the Nvidia settings menu
nvidiaSettings = true;
# Enable nvidia-suspend.service, nvidia-hibernate.service and nvidia-resume.service
powerManagement.enable = true;
};
};
# Load Nvidia driver for Xorg and Wayland
services.xserver.videoDrivers = [ "nvidia" ];
}

View File

@ -15,26 +15,26 @@
];
boot.initrd.availableKernelModules = [
"xhci_pci"
"ahci"
"nvme"
"xhci_pci"
"usb_storage"
"usbhid"
"sd_mod"
"sr_mod"
"sdhci_pci"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-uuid/5e3f0f97-4bb4-4a53-ace2-9ed19ff9e8ea";
fsType = "btrfs";
options = [ "subvol=@" ];
device = "/dev/disk/by-uuid/5ac9c425-35ae-47d5-a683-68ee0dbfc2bc";
fsType = "ext4";
};
boot.initrd.luks.devices."luks-99b73f22-3fa1-42b5-ad48-54b0ccff72cc".device =
"/dev/disk/by-uuid/99b73f22-3fa1-42b5-ad48-54b0ccff72cc";
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/D188-48A9";
device = "/dev/disk/by-uuid/3CFB-D12A";
fsType = "vfat";
options = [
"fmask=0077"
@ -49,10 +49,9 @@
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.eno1.useDHCP = lib.mkDefault true;
# networking.interfaces.enp0s20f0u8.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp6s0.useDHCP = lib.mkDefault true;
# networking.interfaces.enp2s0f0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@ -6,6 +6,7 @@
xdg-desktop-portal-hyprland
hyprpolkitagent # Auth deamon providing modals for password auth
hyprshot # Screenshots
hyprsunset # Blue light filter
# unstable.hyprsysteminfo TODO requires flake update
];

View File

@ -11,7 +11,27 @@
security = {
pam = {
services = {
login.u2fAuth = false; # U2F and password
gdm-fingerprint.text = ''
auth required pam_shells.so
auth requisite pam_nologin.so
auth requisite pam_faillock.so preauth
auth required ${pkgs.fprintd}/lib/security/pam_fprintd.so
auth optional pam_permit.so
auth required pam_env.so
auth [success=ok default=1] ${pkgs.gdm}/lib/security/pam_gdm.so
auth optional ${pkgs.gnome-keyring}/lib/security/pam_gnome_keyring.so
account include login
password required pam_deny.so
session include login
session optional ${pkgs.gnome-keyring}/lib/security/pam_gnome_keyring.so auto_start
'';
login = {
fprintAuth = false;
u2fAuth = false; # U2F and password
};
sudo.u2fAuth = true; # U2F or password
};
u2f = {
@ -24,6 +44,23 @@
};
};
# Start the driver at boot
systemd.services.fprintd = {
wantedBy = [ "multi-user.target" ];
serviceConfig.Type = "simple";
};
# Install the driver
services.fprintd = {
enable = true;
tod.driver = pkgs.libfprint-2-tod1-goodix-550a; # Goodix 550a driver (from Lenovo)
};
# however for focaltech 2808:a658, use fprintd with overidden package (without tod)
# services.fprintd.package = pkgs.fprintd.override {
# libfprint = pkgs.libfprint-focaltech-2808-a658;
# };
services = {
pcscd.enable = true; # Required for Yubikey
udev.packages = with pkgs; [ yubikey-personalization ];