[treewide] reformat all files with nixfmt-rfc-style

This commit is contained in:
Trolli Schmittlauch 2024-03-16 17:18:20 +01:00
parent 3a31c21ae2
commit 2bdff39416
17 changed files with 653 additions and 531 deletions

View file

@ -1,4 +1,9 @@
{ config, lib, pkgs, ...}:
{
config,
lib,
pkgs,
...
}:
{
imports = [
../../common
@ -10,7 +15,6 @@
./secureboot.nix
];
hardware.trackpoint = {
enable = true;
sensitivity = 180;
@ -19,7 +23,6 @@
networking.hostName = "thinknix";
# This value determines the NixOS release with which your system is to be
# compatible, in order to avoid breaking some software such as database
# servers. You should change this only after NixOS release notes say you

View file

@ -1,20 +1,28 @@
{ config, lib, pkgs, modulesPath, ... }:
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports =
[
(modulesPath + "/installer/scan/not-detected.nix")
];
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.availableKernelModules = [ "xhci_pci" "ehci_pci" "ahci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
boot.initrd.availableKernelModules = [
"xhci_pci"
"ehci_pci"
"ahci"
"usb_storage"
"sd_mod"
"rtsx_pci_sdmmc"
];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [];
boot.extraModulePackages = [ ];
nix.settings.max-jobs = lib.mkDefault 4;
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
# modesetting is always better than intel (legacy)
services.xserver.videoDrivers = [ "modesetting" ];
}

View file

@ -1,11 +1,14 @@
{ config, lib, pkgs, ...}:
{
{
config,
lib,
pkgs,
...
}:
{
boot.loader.efi.canTouchEfiVariables = true;
# UEFI secure boot
environment.systemPackages = [
pkgs.sbctl
];
environment.systemPackages = [ pkgs.sbctl ];
# Lanzaboote currently replaces the systemd-boot module.
# This setting is usually set to true in configuration.nix
# generated at installation time. So we force it to false
@ -16,5 +19,4 @@
enable = true;
pkiBundle = "/etc/secureboot";
};
}

View file

@ -1,19 +1,28 @@
{ config, lib, pkgs, ...}:
{
config,
lib,
pkgs,
...
}:
let
fsOptions = [ "noatime" "ssd" "space_cache" "compress=zstd" ];
fsOptions = [
"noatime"
"ssd"
"space_cache"
"compress=zstd"
];
in
{
# encrypted partitions
boot.initrd.luks = {
devices =
# allow discards on all devices
builtins.mapAttrs (name: val: val // {allowDiscards = true;})
{
builtins.mapAttrs (name: val: val // { allowDiscards = true; }) {
"system".device = "/dev/disk/by-uuid/85154131-b2a8-4ef5-9d74-47429cb267ef";
"cryptswap".device = "/dev/disk/by-uuid/ac586df6-6332-4809-beb1-f51906a2adaa";
"ssd2".device = "/dev/disk/by-uuid/cadd4e1f-3642-4faa-8d4e-37dd85465df1";
};
reusePassphrases = true;
reusePassphrases = true;
};
fileSystems = {
@ -57,16 +66,20 @@ in
services.fstrim.enable = true;
services.btrfs.autoScrub = {
enable = true;
fileSystems = [ "/" "/home" ];
fileSystems = [
"/"
"/home"
];
};
boot.tmp.useTmpfs = true;
fileSystems."/tmp".fsType = "tmpfs";
services.smartd =
{
enable = true;
devices = [{ device = "/dev/sda"; } { device = "/dev/sdb"; }];
};
services.smartd = {
enable = true;
devices = [
{ device = "/dev/sda"; }
{ device = "/dev/sdb"; }
];
};
}

View file

@ -1,7 +1,5 @@
{
swapDevices = [
{ device = "/dev/disk/by-uuid/bf928178-4e92-4e7e-8df2-18fbd658eecf"; }
];
swapDevices = [ { device = "/dev/disk/by-uuid/bf928178-4e92-4e7e-8df2-18fbd658eecf"; } ];
zramSwap = {
enable = true;