Global nixfmt

This commit is contained in:
Fabian Hauser 2022-01-03 11:54:05 +01:00
parent 8306da0f09
commit 2bcc955f07
3 changed files with 12 additions and 17 deletions

View file

@ -25,10 +25,7 @@
-----END CERTIFICATE-----
'';
};
dhcpIps = [
"185.88.236.100"
"212.103.68.20"
];
dhcpIps = [ "185.88.236.100" "212.103.68.20" ];
dhcpOptions = with builtins;
concatStringsSep "\n" (map (ip: "dhcp-option DNS ${ip}") dhcpIps);
in {

View file

@ -16,25 +16,25 @@
boot.extraModulePackages = [ ];
boot.kernelParams = [ "acpi_enforce_resources=lax" ];
hardware.firmware = [ pkgs.wireless-regdb ];
hardware.cpu.amd.updateMicrocode = true;
nix.maxJobs = lib.mkDefault 24;
powerManagement.powerUpCommands = let
forceThunderboltOnScript = pkgs.writeScriptBin "force-thunderbolt-power-on" ''
#!${pkgs.stdenv.shell}
forceThunderboltOnScript =
pkgs.writeScriptBin "force-thunderbolt-power-on" ''
#!${pkgs.stdenv.shell}
#echo 'on' > '/sys/bus/pci/devices/0000:03:00.0/power/control'; #TODO: Is the main controller required?
#echo 'on' > '/sys/bus/pci/devices/0000:03:00.0/power/control'; #TODO: Is the main controller required?
THUNDERBOLT_DEVICES="$(${pkgs.pciutils}/bin/lspci -D | ${pkgs.gnugrep}/bin/grep -i thunderbolt | cut --delimiter=' ' --fields=1)"
THUNDERBOLT_DEVICES="$(${pkgs.pciutils}/bin/lspci -D | ${pkgs.gnugrep}/bin/grep -i thunderbolt | cut --delimiter=' ' --fields=1)"
echo "Force PCI power on all thunderbolt devices"
echo "Force PCI power on all thunderbolt devices"
for DEVICE in $THUNDERBOLT_DEVICES; do
echo 'on' > "/sys/bus/pci/devices/$DEVICE/power/control"
done
'';
for DEVICE in $THUNDERBOLT_DEVICES; do
echo 'on' > "/sys/bus/pci/devices/$DEVICE/power/control"
done
'';
in "${forceThunderboltOnScript}/bin/force-thunderbolt-power-on";
}

View file

@ -1,5 +1,3 @@
{ config, lib, pkgs, modulesPath, ... }: {
hardware.rasdaemon = {
enable = true;
};
hardware.rasdaemon = { enable = true; };
}