try to make nvidia module toogleable
This commit is contained in:
parent
02b4a97957
commit
22af8932ee
@ -9,6 +9,8 @@
|
||||
../../modules/nix/virt.nix
|
||||
];
|
||||
|
||||
smayzy.nvidia.enable = true;
|
||||
|
||||
home-manager = {
|
||||
extraSpecialArgs = { inherit inputs; };
|
||||
users = {
|
||||
|
||||
@ -1,5 +1,15 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
let
|
||||
inherit (lib) mkIf mkOption types;
|
||||
in
|
||||
{
|
||||
options.smayzy.nvidia.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = "set to true if you want to use a nvidia GC";
|
||||
};
|
||||
|
||||
config = mkIf config.smayzy.nvidia.enable {
|
||||
services.xserver.videoDrivers = [ "nvidia" ];
|
||||
hardware.nvidia = {
|
||||
modesetting.enable = true;
|
||||
@ -7,4 +17,5 @@
|
||||
nvidiaSettings = true;
|
||||
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user