# Do not modify this file!  It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations.  Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:

{
    imports =
        [ (modulesPath + "/installer/scan/not-detected.nix")
        ];

    boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
    boot.initrd.kernelModules = [ ];
    boot.kernelModules = [ "kvm-intel" ];
    boot.extraModulePackages = [ ];

    fileSystems."/" =
        { device = "rpool/root";
            fsType = "zfs";
        };

    fileSystems."/home" =
        { device = "rpool/home";
            fsType = "zfs";
        };

    fileSystems."/boot" =
        { device = "/dev/disk/by-uuid/5C58-A909";
            fsType = "vfat";
            options = [ "fmask=0022" "dmask=0022" ];
        };

    swapDevices = [ ];

    # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
    # (the default) this is the recommended approach. When using systemd-networkd it's
    # 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.wlp0s20f3.useDHCP = lib.mkDefault true;

    nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
    hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
    hardware.trackpoint.enable = lib.mkDefault true;
    hardware.trackpoint.emulateWheel = lib.mkDefault config.hardware.trackpoint.enable;
    hardware.trackpoint.device = "TPPS/2 Synaptics TrackPoint";
    hardware.ipu6.enable = true;
    hardware.ipu6.platform = "ipu6ep";
    # boot.kernelPackages = pkgs.linuxPackages_latest.extend ( self: super: {
    #     ipu6-drivers = super.ipu6-drivers.overrideAttrs (
    #         final: previous: rec {
    #             src = builtins.fetchGit {
    #                 url = "https://github.com/intel/ipu6-drivers.git";
    #                 ref = "master";
    #                 rev = "b4ba63df5922150ec14ef7f202b3589896e0301a";
    #             };
    #             patches = [
    #                 "${src}/patches/0001-v6.10-IPU6-headers-used-by-PSYS.patch"
    #             ] ;
    #         }
    #     );
    # } );
}