Refactoring configuration

This commit is contained in:
Lyes Saadi 2024-04-10 01:08:29 +02:00
parent 09e3cc520a
commit a87c269dfc
No known key found for this signature in database
GPG key ID: 17418538BAA17767
9 changed files with 336 additions and 287 deletions

View file

@ -0,0 +1,31 @@
{ config, ... }:
{
imports =
[
<nixos-hardware/lenovo/thinkpad/x1-extreme/gen4>
];
services.xserver.videoDrivers = [ "nvidia" ];
hardware.opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
};
hardware.nvidia = {
# Modesetting is needed for most wayland compositors
modesetting.enable = true;
# Use the open source version of the kernel module
# Only available on driver 515.43.04+
open = true;
# Enable the nvidia settings menu
nvidiaSettings = true;
# Optionally, you may need to select the appropriate driver version for your specific GPU
package = config.boot.kernelPackages.nvidiaPackages.stable;
};
}