refactor(repo): reformat to nixfmt; relicense to 0BSD
This commit is contained in:
parent
035fb24038
commit
db2564d828
39 changed files with 451 additions and 318 deletions
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
boot.kernel.sysctl = {
|
||||
"dev.tty.ldisc_autoload" = "0";
|
||||
"fs.protected_fifos" = "2";
|
||||
|
|
|
@ -1,12 +1,11 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
boot.kernel.sysctl = {
|
||||
"vm.dirty_ratio" = 20;
|
||||
"vm.dirty_background_ratio" = 10;
|
||||
"vm.vfs_cache_pressure" = 25;
|
||||
"net.core.default_qdisc" = ''
|
||||
cake'';
|
||||
"net.ipv4.tcp_congestion_control" = ''
|
||||
bbr'';
|
||||
"net.core.default_qdisc" = ''cake'';
|
||||
"net.ipv4.tcp_congestion_control" = ''bbr'';
|
||||
"vm.page-cluster" = 1;
|
||||
"kernel.nmi_watchdog" = 0;
|
||||
"vm.swappiness" = 200;
|
||||
|
@ -22,10 +21,8 @@
|
|||
"net.core.wmem_default" = 1048576;
|
||||
"net.core.wmem_max" = 16777216;
|
||||
"net.core.optmem_max" = 65536;
|
||||
"net.ipv4.tcp_rmem" = ''
|
||||
4096 1048576 2097152'';
|
||||
"net.ipv4.tcp_wmem" = ''
|
||||
4096 65536 16777216'';
|
||||
"net.ipv4.tcp_rmem" = ''4096 1048576 2097152'';
|
||||
"net.ipv4.tcp_wmem" = ''4096 65536 16777216'';
|
||||
"net.ipv4.udp_rmem_min" = 16384;
|
||||
"net.ipv4.udp_wmem_min" = 16384;
|
||||
"net.ipv4.tcp_fastopen" = 3;
|
||||
|
@ -37,7 +34,6 @@
|
|||
"net.ipv4.tcp_keepalive_intvl" = 10;
|
||||
"net.ipv4.tcp_keepalive_probes" = 6;
|
||||
"net.ipv4.tcp_mtu_probing" = 1;
|
||||
"net.ipv4.ip_local_port_range" = ''
|
||||
30000 65535'';
|
||||
"net.ipv4.ip_local_port_range" = ''30000 65535'';
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./hardware.nix
|
||||
./system.nix
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
services.tlp = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
|
|
@ -1,17 +1,35 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
alqueva.system.fonts = {
|
||||
enable = true;
|
||||
names = {
|
||||
sansSerif = ["Liberation Sans"];
|
||||
monospace = ["JetBrainsMono Nerd Font"];
|
||||
serif = ["Liberation Serif"];
|
||||
emoji = ["OpenMoji Color"];
|
||||
sansSerif = [ "Liberation Sans" ];
|
||||
monospace = [ "JetBrainsMono Nerd Font" ];
|
||||
serif = [ "Liberation Serif" ];
|
||||
emoji = [ "OpenMoji Color" ];
|
||||
};
|
||||
packages = {
|
||||
sansSerif = [pkgs.liberation_ttf pkgs.noto-fonts pkgs.noto-fonts-cjk-sans pkgs.noto-fonts-cjk-serif];
|
||||
monospace = [pkgs.nerd-fonts.jetbrains-mono pkgs.noto-fonts];
|
||||
serif = [pkgs.liberation_ttf pkgs.noto-fonts pkgs.noto-fonts pkgs.noto-fonts-cjk-sans pkgs.noto-fonts-cjk-serif];
|
||||
emoji = [pkgs.openmoji-color pkgs.noto-fonts];
|
||||
sansSerif = [
|
||||
pkgs.liberation_ttf
|
||||
pkgs.noto-fonts
|
||||
pkgs.noto-fonts-cjk-sans
|
||||
pkgs.noto-fonts-cjk-serif
|
||||
];
|
||||
monospace = [
|
||||
pkgs.nerd-fonts.jetbrains-mono
|
||||
pkgs.noto-fonts
|
||||
];
|
||||
serif = [
|
||||
pkgs.liberation_ttf
|
||||
pkgs.noto-fonts
|
||||
pkgs.noto-fonts
|
||||
pkgs.noto-fonts-cjk-sans
|
||||
pkgs.noto-fonts-cjk-serif
|
||||
];
|
||||
emoji = [
|
||||
pkgs.openmoji-color
|
||||
pkgs.noto-fonts
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -6,32 +6,40 @@
|
|||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = ["nvme" "xhci_pci"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/41853b7d-f098-4ae6-ae9c-1b97b1074bde";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@"];
|
||||
options = [ "subvol=@" ];
|
||||
};
|
||||
|
||||
boot.initrd.luks.devices."luks-fc6b34e2-c93a-4d14-8194-1c30b63f8fb5".device = "/dev/disk/by-uuid/fc6b34e2-c93a-4d14-8194-1c30b63f8fb5";
|
||||
boot.initrd.luks.devices."luks-fc6b34e2-c93a-4d14-8194-1c30b63f8fb5".device =
|
||||
"/dev/disk/by-uuid/fc6b34e2-c93a-4d14-8194-1c30b63f8fb5";
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/47C4-D06C";
|
||||
fsType = "vfat";
|
||||
options = ["fmask=0077" "dmask=0077"];
|
||||
options = [
|
||||
"fmask=0077"
|
||||
"dmask=0077"
|
||||
];
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{device = "/dev/disk/by-uuid/5743e1ce-4f91-4ab9-9b5d-b46eeda3fb1e";}
|
||||
{ device = "/dev/disk/by-uuid/5743e1ce-4f91-4ab9-9b5d-b46eeda3fb1e"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
networking = {
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
|
@ -29,7 +30,7 @@
|
|||
services.resolved = {
|
||||
enable = true;
|
||||
dnssec = "true";
|
||||
domains = ["~."];
|
||||
domains = [ "~." ];
|
||||
fallbackDns = [
|
||||
"1.1.1.1#cloudflare-dns.com"
|
||||
"1.0.0.1#cloudflare-dns.com"
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
wireplumber = {
|
||||
|
@ -26,12 +27,12 @@
|
|||
"support.*" = "support/libspa-support";
|
||||
};
|
||||
"modules" = [
|
||||
{"name" = "libpipewire-module-protocol-native";}
|
||||
{"name" = "libpipewire-module-client-node";}
|
||||
{"name" = "libpipewire-module-client-device";}
|
||||
{"name" = "libpipewire-module-adapter";}
|
||||
{"name" = "libpipewire-module-metadata";}
|
||||
{"name" = "libpipewire-module-session-manager";}
|
||||
{ "name" = "libpipewire-module-protocol-native"; }
|
||||
{ "name" = "libpipewire-module-client-node"; }
|
||||
{ "name" = "libpipewire-module-client-device"; }
|
||||
{ "name" = "libpipewire-module-adapter"; }
|
||||
{ "name" = "libpipewire-module-metadata"; }
|
||||
{ "name" = "libpipewire-module-session-manager"; }
|
||||
];
|
||||
};
|
||||
"filter" = {
|
||||
|
@ -67,14 +68,17 @@
|
|||
"rt.time.soft" = -1;
|
||||
"rt.time.hard" = -1;
|
||||
};
|
||||
"flags" = ["ifexists" "nofail"];
|
||||
"flags" = [
|
||||
"ifexists"
|
||||
"nofail"
|
||||
];
|
||||
}
|
||||
{"name" = "libpipewire-module-protocol-native";}
|
||||
{"name" = "libpipewire-module-client-node";}
|
||||
{"name" = "libpipewire-module-client-device";}
|
||||
{"name" = "libpipewire-module-adapter";}
|
||||
{"name" = "libpipewire-module-metadata";}
|
||||
{"name" = "libpipewire-module-session-manager";}
|
||||
{ "name" = "libpipewire-module-protocol-native"; }
|
||||
{ "name" = "libpipewire-module-client-node"; }
|
||||
{ "name" = "libpipewire-module-client-device"; }
|
||||
{ "name" = "libpipewire-module-adapter"; }
|
||||
{ "name" = "libpipewire-module-metadata"; }
|
||||
{ "name" = "libpipewire-module-session-manager"; }
|
||||
];
|
||||
};
|
||||
"filter" = {
|
||||
|
@ -147,7 +151,10 @@
|
|||
"uclamp.min" = 0;
|
||||
"uclamp.max" = 2048;
|
||||
};
|
||||
"flags" = ["ifexists" "nofail"];
|
||||
"flags" = [
|
||||
"ifexists"
|
||||
"nofail"
|
||||
];
|
||||
}
|
||||
{
|
||||
"name" = "libpipewire-module-protocol-native";
|
||||
|
@ -163,7 +170,7 @@
|
|||
}
|
||||
{
|
||||
"name" = "libpipewire-module-protocol-pulse";
|
||||
"args" = {};
|
||||
"args" = { };
|
||||
}
|
||||
];
|
||||
"exec" = [
|
||||
|
@ -177,22 +184,22 @@
|
|||
{
|
||||
"cmd" = "load-module";
|
||||
"args" = "module-always-sink";
|
||||
"flags" = [];
|
||||
"flags" = [ ];
|
||||
}
|
||||
{
|
||||
"cmd" = "load-module";
|
||||
"args" = "module-device-manager";
|
||||
"flags" = [];
|
||||
"flags" = [ ];
|
||||
}
|
||||
{
|
||||
"cmd" = "load-module";
|
||||
"args" = "module-device-restore";
|
||||
"flags" = [];
|
||||
"flags" = [ ];
|
||||
}
|
||||
{
|
||||
"cmd" = "load-module";
|
||||
"args" = "module-stream-restore";
|
||||
"flags" = [];
|
||||
"flags" = [ ];
|
||||
}
|
||||
{
|
||||
"cmd" = "load-module";
|
||||
|
@ -201,7 +208,7 @@
|
|||
{
|
||||
"cmd" = "load-module";
|
||||
"args" = "module-gsettings";
|
||||
"flags" = ["nofail"];
|
||||
"flags" = [ "nofail" ];
|
||||
}
|
||||
];
|
||||
"properties" = {
|
||||
|
@ -237,7 +244,10 @@
|
|||
"context.data-loops" = [
|
||||
{
|
||||
"loop.rt-prio" = -1;
|
||||
"loop.class" = ["data.rt" "audio.rt"];
|
||||
"loop.class" = [
|
||||
"data.rt"
|
||||
"audio.rt"
|
||||
];
|
||||
"library.name.system" = "support/libspa-support";
|
||||
"thread.name" = "data-loop.0";
|
||||
}
|
||||
|
@ -245,7 +255,7 @@
|
|||
"core.daemon" = true;
|
||||
"core.name" = "pipewire-0";
|
||||
"default.clock.rate" = 192000;
|
||||
"default.clock.allowed-rates" = [192000];
|
||||
"default.clock.allowed-rates" = [ 192000 ];
|
||||
"module.x11.bell" = true;
|
||||
"module.access" = true;
|
||||
"module.jackdbus-detect" = true;
|
||||
|
@ -287,7 +297,10 @@
|
|||
"uclamp.min" = 0;
|
||||
"uclamp.max" = 2048;
|
||||
};
|
||||
"flags" = ["ifexists" "nofail"];
|
||||
"flags" = [
|
||||
"ifexists"
|
||||
"nofail"
|
||||
];
|
||||
}
|
||||
{
|
||||
"name" = "libpipewire-module-protocol-native";
|
||||
|
@ -304,7 +317,10 @@
|
|||
}
|
||||
{
|
||||
"name" = "libpipewire-module-portal";
|
||||
"flags" = ["ifexists" "nofail"];
|
||||
"flags" = [
|
||||
"ifexists"
|
||||
"nofail"
|
||||
];
|
||||
}
|
||||
{
|
||||
"name" = "libpipewire-module-access";
|
||||
|
@ -328,7 +344,10 @@
|
|||
"x11.display" = null;
|
||||
"x11.xauthority" = null;
|
||||
};
|
||||
"flags" = ["ifexists" "nofail"];
|
||||
"flags" = [
|
||||
"ifexists"
|
||||
"nofail"
|
||||
];
|
||||
"condition" = [
|
||||
{
|
||||
"module.x11.bell" = true;
|
||||
|
@ -338,10 +357,13 @@
|
|||
{
|
||||
"name" = "libpipewire-module-jackdbus-detect";
|
||||
"args" = {
|
||||
"source.props" = {};
|
||||
"sink.props" = {};
|
||||
"source.props" = { };
|
||||
"sink.props" = { };
|
||||
};
|
||||
"flags" = ["ifexists" "nofail"];
|
||||
"flags" = [
|
||||
"ifexists"
|
||||
"nofail"
|
||||
];
|
||||
"condition" = [
|
||||
{
|
||||
"module.jackdbus-detect" = true;
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
programs.ssh = {
|
||||
startAgent = true;
|
||||
enableAskPassword = true;
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./config/sysctl.d/performance.nix
|
||||
./config/sysctl.d/hardening.nix
|
||||
|
@ -57,7 +58,7 @@
|
|||
enable = true;
|
||||
package = pkgs.scx_git.rustscheds;
|
||||
scheduler = "scx_lavd";
|
||||
extraArgs = ["--performance"];
|
||||
extraArgs = [ "--performance" ];
|
||||
};
|
||||
|
||||
boot.runSize = "100%";
|
||||
|
@ -69,11 +70,16 @@
|
|||
|
||||
fileSystems."/" = {
|
||||
fsType = "btrfs";
|
||||
options = ["compress=zstd:6" "discard" "flushoncommit" "subvol=@"];
|
||||
options = [
|
||||
"compress=zstd:6"
|
||||
"discard"
|
||||
"flushoncommit"
|
||||
"subvol=@"
|
||||
];
|
||||
};
|
||||
|
||||
services.btrfs.autoScrub = {
|
||||
fileSystems = ["/"]; # Assuming root is formatted with Btrfs.
|
||||
fileSystems = [ "/" ]; # Assuming root is formatted with Btrfs.
|
||||
interval = "daily";
|
||||
enable = true;
|
||||
};
|
||||
|
@ -101,7 +107,11 @@
|
|||
use-cgroups = true;
|
||||
};
|
||||
|
||||
boot.initrd.kernelModules = ["amdgpu" "sha256" "sha512"];
|
||||
boot.initrd.kernelModules = [
|
||||
"amdgpu"
|
||||
"sha256"
|
||||
"sha512"
|
||||
];
|
||||
|
||||
# Processor settings for AMD
|
||||
hardware.cpu.amd = {
|
||||
|
@ -115,8 +125,12 @@
|
|||
# Bootloader.
|
||||
boot.loader.systemd-boot = {
|
||||
enable = true;
|
||||
edk2-uefi-shell = {enable = true;};
|
||||
memtest86 = {enable = true;};
|
||||
edk2-uefi-shell = {
|
||||
enable = true;
|
||||
};
|
||||
memtest86 = {
|
||||
enable = true;
|
||||
};
|
||||
configurationLimit = 3;
|
||||
};
|
||||
|
||||
|
@ -139,7 +153,7 @@
|
|||
|
||||
# Enable the X11 windowing system.
|
||||
services.xserver.enable = true;
|
||||
services.xserver.videoDrivers = ["amdgpu"];
|
||||
services.xserver.videoDrivers = [ "amdgpu" ];
|
||||
services.xserver.updateDbusEnvironment = true;
|
||||
services.xserver.enableTearFree = true;
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
{...}: {
|
||||
{ ... }:
|
||||
{
|
||||
qt = {
|
||||
platformTheme = "qt5ct";
|
||||
style = "kvantum";
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
alqueva.users.unix = {
|
||||
shell = pkgs.zsh;
|
||||
packages = builtins.attrValues {
|
||||
inherit
|
||||
(pkgs)
|
||||
inherit (pkgs)
|
||||
wget2
|
||||
fastfetch
|
||||
btop-rocm
|
||||
|
@ -29,21 +29,18 @@
|
|||
man-pages-posix
|
||||
xwayland-satellite
|
||||
;
|
||||
inherit
|
||||
(pkgs.nodePackages_latest)
|
||||
inherit (pkgs.nodePackages_latest)
|
||||
nodejs
|
||||
pnpm
|
||||
;
|
||||
inherit
|
||||
(pkgs.llvmPackages_19)
|
||||
inherit (pkgs.llvmPackages_19)
|
||||
libcxxClang
|
||||
clangUseLLVM
|
||||
clang-tools
|
||||
clang-manpages
|
||||
openmp
|
||||
;
|
||||
inherit
|
||||
(pkgs.emacsPackages)
|
||||
inherit (pkgs.emacsPackages)
|
||||
tree-sitter
|
||||
tsc
|
||||
tree-sitter-langs
|
||||
|
@ -91,7 +88,7 @@
|
|||
enableCompletion = true;
|
||||
autosuggestions = {
|
||||
enable = true;
|
||||
strategy = ["completion"];
|
||||
strategy = [ "completion" ];
|
||||
};
|
||||
|
||||
zsh-autoenv = {
|
||||
|
@ -100,7 +97,15 @@
|
|||
|
||||
syntaxHighlighting = {
|
||||
enable = true;
|
||||
highlighters = ["main" "brackets" "pattern" "cursor" "regexp" "root" "line"];
|
||||
highlighters = [
|
||||
"main"
|
||||
"brackets"
|
||||
"pattern"
|
||||
"cursor"
|
||||
"regexp"
|
||||
"root"
|
||||
"line"
|
||||
];
|
||||
};
|
||||
|
||||
shellAliases = {
|
||||
|
@ -111,7 +116,12 @@
|
|||
|
||||
ohMyZsh = {
|
||||
enable = true;
|
||||
plugins = ["git" "direnv" "fzf" "ssh-agent"];
|
||||
plugins = [
|
||||
"git"
|
||||
"direnv"
|
||||
"fzf"
|
||||
"ssh-agent"
|
||||
];
|
||||
preLoaded = "zstyle :omz:plugins:ssh-agent agent-forwarding yes";
|
||||
theme = "half-life";
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue