framework setup

This commit is contained in:
Kopatz
2025-04-28 15:38:34 +02:00
parent 041bfd26aa
commit 61d6e8c876
6 changed files with 23 additions and 21 deletions

View File

@@ -34,7 +34,7 @@ in
"Unknown-1,disable"
] else if isLaptop then [
# laptop
"eDP-1,1920x1080@60,0x0,1"
"eDP-1,2256x1504@60,0x0,1.33"
#"DP-3,1920x1080@60,1920x0,1"
#",preferred,auto,1,mirror,eDP-1"
",preferred,auto,auto"

View File

@@ -35,7 +35,6 @@
#android.enable = true;
};
#emulators.enable = true;
gnome.enable = true;
hyprland.enable = true;
#games.enable = true;
ime.enable = true;
@@ -49,6 +48,15 @@
};
nixpkgs.config.permittedInsecurePackages = [ "electron-27.3.11" "electron-28.3.3" ];
services.fprintd.enable = true;
#todo: extract this
services.xserver = {
xkb.layout = config.mainUser.layout;
xkb.variant = config.mainUser.variant;
enable = true;
displayManager.gdm.enable = true;
};
#programs.firejail.wrappedBinaries = with pkgs;
# let inherit (config.custom.misc.firejail) mk;
# in lib.mkMerge [

View File

@@ -13,6 +13,7 @@ in
environment.systemPackages = with pkgs; [
man-pages
jetbrains.idea-ultimate
jetbrains.rider
typescript
#jetbrains.clion
insomnia

View File

@@ -1,4 +1,5 @@
{ config, pkgs, inputs, ... }: {
{ config, pkgs, inputs, lib, ... }:
{
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix
@@ -16,19 +17,9 @@
## -- set in flake.nix
#<nixos-hardware/dell/xps/15-7590/nvidia>
#<home-manager/nixos>
inputs.nixos-hardware.nixosModules.dell-xps-15-7590
inputs.nixos-hardware.nixosModules.framework-13-7040-amd
];
specialisation.nvidia = {
configuration = {
imports = [ inputs.nixos-hardware.nixosModules.dell-xps-15-7590-nvidia ];
hardware.nvidia.package =
config.boot.kernelPackages.nvidiaPackages.production;
hardware.nvidia.open = false;
};
};
#services.blueman.enable = true;
#hardware.bluetooth.enable = true; # enables support for Bluetooth
@@ -37,8 +28,8 @@
age.identityPaths =
[ "/home/kopatz/.ssh/id_ed25519" "/etc/ssh/ssh_host_ed25519_key" ];
mainUser.layout = "at";
mainUser.variant = "";
mainUser.layout = "de";
mainUser.variant = "us";
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;

View File

@@ -9,9 +9,11 @@
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "uas" "sd_mod" "rtsx_pci_sdmmc" ];
# boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "uas" "sd_mod" "rtsx_pci_sdmmc" "thunderbolt"];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "thunderbolt" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
@@ -37,5 +39,5 @@
# networking.interfaces.wlp59s0.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

@@ -15,8 +15,8 @@
CPU_SCALING_GOVERNOR_ON_AC = "performance";
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
#CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
CPU_ENERGY_PERF_POLICY_ON_BAT = "balance_power";
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
#CPU_ENERGY_PERF_POLICY_ON_BAT = "balance_power";
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
CPU_MIN_PERF_ON_AC = 0;