current
This commit is contained in:
parent
24aa0a58e4
commit
76c91fc817
9 changed files with 232 additions and 64 deletions
|
|
@ -1,14 +1,17 @@
|
|||
{ lib, pkgs, modulesPath, ... }: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
# exfatprogs
|
||||
# rustup
|
||||
appimage-run
|
||||
bat
|
||||
bottom
|
||||
cifs-utils
|
||||
du-dust
|
||||
ffmpeg
|
||||
firefox
|
||||
git
|
||||
helix
|
||||
mesa
|
||||
mpv
|
||||
nfs-utils
|
||||
nil
|
||||
|
|
@ -16,14 +19,17 @@
|
|||
onlyoffice-bin
|
||||
ouch
|
||||
ripgrep-all
|
||||
# rustup
|
||||
skim
|
||||
snapper
|
||||
tree
|
||||
unstable.yazi
|
||||
unstable.joshuto
|
||||
unstable.oculante
|
||||
wezterm
|
||||
wget
|
||||
zstd
|
||||
yt-dlp
|
||||
ffmpeg
|
||||
zathura
|
||||
zstd
|
||||
];
|
||||
programs.partition-manager.enable = true;
|
||||
|
||||
|
|
@ -31,6 +37,7 @@
|
|||
services.openssh.enable = lib.mkDefault true;
|
||||
services.flatpak.enable = lib.mkDefault true;
|
||||
services.printing.enable = lib.mkDefault true;
|
||||
services.btrfs.autoScrub.enable = true;
|
||||
|
||||
environment.variables = {
|
||||
EDITOR = "hx";
|
||||
|
|
@ -57,7 +64,23 @@
|
|||
boot.loader.timeout = 0;
|
||||
boot.supportedFilesystems = [ "ntfs" ];
|
||||
|
||||
networking.networkmanager.enable = true;
|
||||
networking.networkmanager = {
|
||||
enable = true;
|
||||
# dispatcherScripts = [{
|
||||
# source = pkgs.writeText "upHook" ''
|
||||
# logger "event $2"
|
||||
# if [ "$2" == "vpn-up" ]; then
|
||||
# iptables -A OUTPUT -o tun0 -j ACCEPT
|
||||
# iptables -A OUTPUT ! -o tun0 -j DROP
|
||||
# fi
|
||||
# if [ "$2" == "vpn-down" ]; then
|
||||
# iptables -D OUTPUT -o tun0 -j ACCEPT
|
||||
# iptables -D OUTPUT ! -o tun0 -j DROP
|
||||
# fi
|
||||
# '';
|
||||
# type = "basic";
|
||||
# }];
|
||||
};
|
||||
networking.firewall.enable = false;
|
||||
|
||||
services.xserver.enable = true;
|
||||
|
|
@ -68,6 +91,7 @@
|
|||
environment.plasma5.excludePackages = with pkgs.libsForQt5; [
|
||||
elisa
|
||||
konsole
|
||||
gwenview
|
||||
];
|
||||
|
||||
services.pipewire = {
|
||||
|
|
@ -89,6 +113,7 @@
|
|||
|
||||
time.timeZone = "US/Pacific";
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
i18n.supportedLocales = [ "all" ];
|
||||
|
||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,10 @@
|
|||
{ lib, pkgs, ... }:
|
||||
{
|
||||
{ lib, pkgs, ... }: {
|
||||
services.xserver.displayManager = {
|
||||
autoLogin.enable = true;
|
||||
autoLogin.user = "tao";
|
||||
};
|
||||
|
||||
|
||||
environment.systemPackages = with pkgs;
|
||||
[
|
||||
# mesa
|
||||
|
|
@ -10,16 +15,23 @@
|
|||
# nvidia-vaapi-driver
|
||||
];
|
||||
|
||||
|
||||
environment.sessionVariables = {
|
||||
# wayland chromium workaround
|
||||
NIXOS_OZONE_WL = "1";
|
||||
};
|
||||
|
||||
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/eb9fcce2-e9f3-438a-b5ce-8f72f32f0e09";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=home_snaps/0/snapshot" "noatime" "compress-force=zstd:3" ];
|
||||
};
|
||||
fileSystems."/home/.snapshots" = {
|
||||
device = "/dev/disk/by-uuid/eb9fcce2-e9f3-438a-b5ce-8f72f32f0e09";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=home_snaps/" "noatime" "compress-force=zstd:3" ];
|
||||
};
|
||||
fileSystems."/home/tao/Games" = {
|
||||
device = "/dev/disk/by-uuid/eb9fcce2-e9f3-438a-b5ce-8f72f32f0e09";
|
||||
fsType = "btrfs";
|
||||
|
|
@ -45,9 +57,23 @@
|
|||
fsType = "btrfs";
|
||||
options = [ "subvol=nixos/tmp" ];
|
||||
};
|
||||
|
||||
swapDevices = [{ device = "/dev/disk/by-uuid/ca0ed3d7-8758-4ac7-b016-8b4cd9608ded"; }];
|
||||
|
||||
|
||||
services.snapper.configs =
|
||||
{
|
||||
home = {
|
||||
SUBVOLUME = "/home";
|
||||
ALLOW_USERS = [ "tao" ];
|
||||
TIMELINE_CREATE = true;
|
||||
TIMELINE_CLEANUP = true;
|
||||
TIMELINE_LIMIT_HOURLY = "5";
|
||||
TIMELINE_LIMIT_DAILY = "7";
|
||||
};
|
||||
};
|
||||
services.snapper.snapshotInterval = "*:0/5";
|
||||
|
||||
|
||||
# systemd.user.services.fans = {
|
||||
# description = "NZXT fans to 69% using liquidctl";
|
||||
# script = ''
|
||||
|
|
@ -56,10 +82,13 @@
|
|||
# wantedBy = [ "default.target" ];
|
||||
# };
|
||||
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
|
||||
# boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
boot.kernelPackages = pkgs.unstable.linuxPackages_latest;
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ];
|
||||
boot.kernelModules = [ "i2c-dev" "kvm-amd" ];
|
||||
|
||||
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
|
|
@ -67,8 +96,9 @@
|
|||
};
|
||||
hardware.nvidia = {
|
||||
modesetting.enable = true;
|
||||
powerManagement.enable = true;
|
||||
# package = config.boot.kernelPackages.nvidiaPackages.beta;
|
||||
# package = pkgs.unstable.linuxPackages_latest.nvidiaPackages.production;
|
||||
package = pkgs.unstable.linuxPackages_latest.nvidiaPackages.production;
|
||||
};
|
||||
# enable core and mem freq sliders for nvidia
|
||||
services.xserver.deviceSection = ''
|
||||
|
|
@ -80,10 +110,13 @@
|
|||
wantedBy = [ "multi-user.target" ];
|
||||
};
|
||||
|
||||
|
||||
services.udev.packages = [ pkgs.openrgb ];
|
||||
services.udev.extraRules = ''
|
||||
KERNEL=="hidraw*", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="a3c5", MODE="0666"
|
||||
'';
|
||||
|
||||
|
||||
time.hardwareClockInLocalTime = true;
|
||||
networking.hostName = "NOcomputer";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
{ pkgs, ... }: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
intel-gpu-tools
|
||||
# libsForQt5.skanpage
|
||||
powertop
|
||||
];
|
||||
|
||||
fileSystems."/home" = {
|
||||
|
|
@ -26,10 +28,10 @@
|
|||
powerManagement.powertop.enable = true;
|
||||
hardware.sensor.iio.enable = true;
|
||||
|
||||
hardware.sane = {
|
||||
enable = true;
|
||||
extraBackends = [ pkgs.epkowa ];
|
||||
};
|
||||
# hardware.sane = {
|
||||
# enable = true;
|
||||
# extraBackends = [ pkgs.epkowa ];
|
||||
# };
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
|
|
@ -41,10 +43,28 @@
|
|||
boot.kernelParams = [
|
||||
"mem_sleep_default=deep"
|
||||
"nvme.noacpi=1"
|
||||
"i915.eanble_psr=1"
|
||||
];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
powerManagement.cpuFreqGovernor = "powersave";
|
||||
systemd.sleep.extraConfig = "HibernateDelaySec=60m";
|
||||
|
||||
services.pipewire.wireplumber.enable = true;
|
||||
environment.etc = {
|
||||
"wireplumber/main.lua.d/51-fix-static.lua".text = ''
|
||||
rule = {
|
||||
matches = {
|
||||
{
|
||||
{ "node.name", "equals", "alsa_output.pci-0000_00_1f.3.analog-stereo.3" },
|
||||
},
|
||||
},
|
||||
apply_properties = {
|
||||
[ "audio.format" ] = "S24LE" ,
|
||||
},
|
||||
}
|
||||
table.insert(alsa_monitor.rules, rule)
|
||||
'';
|
||||
};
|
||||
|
||||
networking.hostName = "NOlaptop";
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue