Housekeeping

- Update README
- Run shellcheck on .sh files
- Add helper scripts
- Remove eirene vm variant
- Add post-install checklist

Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
2024-08-23 01:22:08 +02:00
parent a048be5c51
commit 78a862bd2e
29 changed files with 582 additions and 434 deletions

View File

@@ -1,5 +1,14 @@
{
inputs,
lib,
pkgs,
...
}:
{
imports = [
inputs.disko.nixosModules.disko
(import ./format.nix { device = "/dev/disk/by-id/nvme-SAMSUNG_MZVL22T0HBLB-00BL2_S64RNE0R602762"; })
./hardware-configuration.nix
../common/system/configs/bluetooth
../common/system/configs/boot
../common/system/configs/brightnessctl
@@ -27,15 +36,98 @@
../common/system/configs/ssh
../common/system/configs/system
../common/system/configs/timezone
../common/system/configs/tlp
../common/system/configs/tmux
../common/system/configs/tree
../common/system/configs/users
../common/system/configs/wget
../common/system/configs/zsh
../common/system/scripts/cleanup
./nick.nix
./users/nick.nix
];
# https://github.com/NixOS/nixos-hardware/tree/master/lenovo/legion/16achg6
hardware = {
enableAllFirmware = true;
cpu = {
cores = 8;
threads = 16;
amd.updateMicrocode = true;
};
nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
open = false;
prime = {
offload = {
enable = true;
enableOffloadCmd = true;
};
nvidiaBusId = "PCI:1:0:0";
amdgpuBusId = "PCI:6:0:0";
};
};
graphics = {
enable32Bit = true;
extraPackages = with pkgs; [
amdvlk
driversi686Linux.amdvlk
rocmPackages.clr
rocmPackages.clr.icd
];
};
};
networking.hostName = "eirene";
i18n.defaultLocale = "en_US.UTF-8";
sops.defaultSopsFile = ./secrets/secrets.yaml;
services = {
xserver.videoDrivers = [ "nvidia" ];
fstrim.enable = true;
tlp.settings.DISK_DEVICES = "nvme0n1 nvme1n1";
};
boot = {
kernelParams = [
"amd_pstate=active"
"video=eDP-1:2560x1600@165"
];
initrd.kernelModules = [ "amdgpu" ];
};
nixpkgs.config = {
cudaSupport = true;
rocmSupport = true;
};
home-manager.sharedModules = [
{
wayland.windowManager.hyprland.settings = {
monitor = "eDP-1, 2560x1600@165, 0x0, 1.25";
env = [ "WLR_DRM_DEVICES,$HOME/.config/hypr/card" ];
device = [
{
name = "syna2ba6:00-06cb:ce44-touchpad";
sensitivity = 0.5;
}
];
gestures.workspace_swipe_distance = 600;
};
programs = {
zsh.loginExtra = lib.mkBefore (builtins.readFile ./scripts/card.sh);
# VSCode does not play well with fractional scaling
vscode.userSettings."window.zoomLevel" = (1.25 - 1) / 0.2;
};
theme = {
cursor.size = 24;
};
}
];
}