Add linting, formatting, and CI infrastructure

- Add deadnix, nixfmt, and statix to flake inputs
- Add formatter output to flake for nix fmt support
- Add deadnix, nixfmt, statix to Home Manager packages
- Add GitHub Actions workflow for CI validation
- Add .pre-commit-config.yaml with hooks for nixfmt, deadnix, and statix
- Support x86_64-darwin in formatter
This commit is contained in:
Gene Liverman 2026-03-22 18:32:20 -04:00
parent 582f93d9ed
commit 5dbcce7686
No known key found for this signature in database
76 changed files with 1522 additions and 831 deletions

View file

@ -1,4 +1,10 @@
{ config, pkgs, username, ... }: {
{
config,
pkgs,
username,
...
}:
{
imports = [
./disk-config.nix
./hardware-configuration.nix
@ -17,16 +23,16 @@
device = "nodev";
mirroredBoots = [
{
devices = ["/dev/disk/by-uuid/02A5-6FCC"];
devices = [ "/dev/disk/by-uuid/02A5-6FCC" ];
path = "/boot";
}
{
devices = ["/dev/disk/by-uuid/02F1-B12D"];
devices = [ "/dev/disk/by-uuid/02F1-B12D" ];
path = "/boot-fallback";
}
];
};
supportedFilesystems = ["zfs"];
supportedFilesystems = [ "zfs" ];
zfs = {
extraPools = [ "storage" ];
forceImportRoot = false;

View file

@ -1,4 +1,3 @@
{ ... }:
{
disko.devices = {
disk = {
@ -124,4 +123,4 @@
}; # end zroot
};
};
}
}

View file

@ -1,46 +1,72 @@
# 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, modulesPath, ... }:
{
config,
lib,
modulesPath,
...
}:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "ehci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ "nvme" ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
boot = {
initrd = {
availableKernelModules = [
"ehci_pci"
"ahci"
"usbhid"
"usb_storage"
"sd_mod"
"sr_mod"
];
kernelModules = [ "nvme" ];
};
kernelModules = [ "kvm-intel" ];
extraModulePackages = [ ];
};
fileSystems."/" =
{ device = "zroot/root";
fileSystems = {
"/" = {
device = "zroot/root";
fsType = "zfs";
};
fileSystems."/nix" =
{ device = "zroot/root/nix";
"/nix" = {
device = "zroot/root/nix";
fsType = "zfs";
};
fileSystems."/home" =
{ device = "zroot/root/home";
"/home" = {
device = "zroot/root/home";
fsType = "zfs";
};
fileSystems."/boot" =
# { device = "/dev/disk/by-uuid/02A5-6FCC";
{ device = "/dev/disk/by-partlabel/disk-sdc-BOOT";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
"/boot" =
# { device = "/dev/disk/by-uuid/02A5-6FCC";
{
device = "/dev/disk/by-partlabel/disk-sdc-BOOT";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
};
fileSystems."/boot-fallback" =
# { device = "/dev/disk/by-uuid/02F1-B12D";
{ device = "/dev/disk/by-partlabel/disk-sdd-BOOT-FALLBACK";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
"/boot-fallback" =
# { device = "/dev/disk/by-uuid/02F1-B12D";
{
device = "/dev/disk/by-partlabel/disk-sdd-BOOT-FALLBACK";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
};
};
swapDevices = [ ];

View file

@ -1,3 +1,3 @@
{ ... }: {
home.stateVersion = "24.05";
{
home.stateVersion = "24.05";
}