Implemented custom system for creating and distributing color schemes based on wallpapers, and also cycling through wallpapers.

nixfmt'd the codebase
This commit is contained in:
2026-03-09 22:02:46 -04:00
parent 4308b8eb16
commit 8ee748a997
145 changed files with 2776 additions and 1125 deletions

View File

@@ -1,4 +1,9 @@
{ inputs, pkgs, username, ... }:
{
inputs,
pkgs,
username,
...
}:
let
shed = inputs.shed.packages.${pkgs.stdenv.hostPlatform.system}.default;
@@ -31,8 +36,14 @@ in
};
environment = {
variables = { PATH = "${pkgs.clang-tools}/bin:$PATH"; };
shells = [ pkgs.myPkgs.slash pkgs.zsh pkgs.bash ];
variables = {
PATH = "${pkgs.clang-tools}/bin:$PATH";
};
shells = [
pkgs.myPkgs.slash
pkgs.zsh
pkgs.bash
];
};
users = {
@@ -43,7 +54,12 @@ in
isNormalUser = true;
initialPassword = "1234";
shell = shed;
extraGroups = [ "input" "wheel" "persist" "libvirtd" ];
extraGroups = [
"input"
"wheel"
"persist"
"libvirtd"
];
};
};
};

View File

@@ -1,28 +1,44 @@
# 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, pkgs, modulesPath, ... }:
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];
imports = [
(modulesPath + "/profiles/qemu-guest.nix")
];
boot.initrd.availableKernelModules = [ "ahci" "xhci_pci" "virtio_pci" "virtio_scsi" "sr_mod" "virtio_blk" ];
boot.initrd.availableKernelModules = [
"ahci"
"xhci_pci"
"virtio_pci"
"virtio_scsi"
"sr_mod"
"virtio_blk"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/5d8dd8ba-6c4c-4227-adc5-f33bf0022fff";
fsType = "ext4";
};
fileSystems."/" = {
device = "/dev/disk/by-uuid/5d8dd8ba-6c4c-4227-adc5-f33bf0022fff";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/6A3C-0A12";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/6A3C-0A12";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
};
swapDevices = [ ];

View File

@@ -1,7 +1,7 @@
{ username, ... }: {
{ username, ... }:
{
home.username = "${username}";
home.homeDirectory =
"/home/${username}";
home.homeDirectory = "/home/${username}";
home.stateVersion = "25.05";
programs.home-manager.enable = true;
@@ -14,7 +14,10 @@
envConfig = {
hyprlandConfig = {
enable = true;
monitorNames = [ "HDMI-A-1" "DP-1" ];
monitorNames = [
"HDMI-A-1"
"DP-1"
];
workspaceLayout = "dualmonitor";
};
userPkgs.enable = true;

View File

@@ -1,10 +1,21 @@
{ username, pkgs, config, ... }: {
{
username,
pkgs,
config,
...
}:
{
imports = [ ./hardware.nix ];
boot = {
kernelModules = [ "acpi_call" ];
extraModulePackages = with config.boot.kernelPackages;
[ acpi_call cpupower ] ++ [ pkgs.cpupower-gui ];
extraModulePackages =
with config.boot.kernelPackages;
[
acpi_call
cpupower
]
++ [ pkgs.cpupower-gui ];
};
movOpts = {
@@ -27,9 +38,19 @@
};
environment = {
variables = { PATH = "${pkgs.clang-tools}/bin:$PATH"; };
shells = with pkgs; [ zsh bash ];
systemPackages = with pkgs; [ acpi brightnessctl cpupower-gui powertop ];
variables = {
PATH = "${pkgs.clang-tools}/bin:$PATH";
};
shells = with pkgs; [
zsh
bash
];
systemPackages = with pkgs; [
acpi
brightnessctl
cpupower-gui
powertop
];
};
users = {
@@ -40,7 +61,11 @@
isNormalUser = true;
initialPassword = "1234";
shell = pkgs.zsh;
extraGroups = [ "wheel" "persist" "libvirtd" ];
extraGroups = [
"wheel"
"persist"
"libvirtd"
];
};
};
};

View File

@@ -1,11 +1,24 @@
# 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, pkgs, modulesPath, ... }: {
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.availableKernelModules =
[ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.availableKernelModules = [
"nvme"
"xhci_pci"
"ahci"
"usbhid"
"usb_storage"
"sd_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
@@ -23,7 +36,10 @@
fileSystems."/boot" = {
device = "/dev/sda2";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
options = [
"fmask=0077"
"dmask=0077"
];
};
fileSystems."/home" = {
@@ -42,6 +58,5 @@
# networking.interfaces.wlp15s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@@ -1,9 +1,17 @@
{ host, pkgs, self, inputs, username, lib, config, ... }: {
{
host,
pkgs,
self,
inputs,
username,
lib,
config,
...
}:
{
home.username = "${username}"; # Replace with your actual username
home.homeDirectory =
"/home/${username}"; # Replace with your actual home directory
home.stateVersion =
"24.05"; # Adjust this based on your system's NixOS version
home.homeDirectory = "/home/${username}"; # Replace with your actual home directory
home.stateVersion = "24.05"; # Adjust this based on your system's NixOS version
programs.home-manager.enable = true;

View File

@@ -1,4 +1,5 @@
{ pkgs, username, ... }: {
{ pkgs, username, ... }:
{
imports = [ ./hardware.nix ];
movOpts = {
sysEnv = {
@@ -22,7 +23,12 @@
caddyConfig.enable = true;
};
};
networking.firewall = { allowedTCPPorts = [ 443 8920 ]; };
networking.firewall = {
allowedTCPPorts = [
443
8920
];
};
environment = {
etc."tmpfiles.d/home-permissions.conf".text = ''
d /home/pagedmov 0750 pagedmov users -
@@ -31,7 +37,10 @@
PATH = "${pkgs.clang-tools}/bin:$PATH";
TERM = "kitty";
};
shells = with pkgs; [ zsh bash ];
shells = with pkgs; [
zsh
bash
];
};
users = {
@@ -42,7 +51,11 @@
isNormalUser = true;
initialPassword = "1234";
shell = pkgs.zsh;
extraGroups = [ "wheel" "persist" "libvirtd" ];
extraGroups = [
"wheel"
"persist"
"libvirtd"
];
};
};
};

View File

@@ -1,13 +1,25 @@
# 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, pkgs, modulesPath, ... }:
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.availableKernelModules =
[ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.availableKernelModules = [
"nvme"
"xhci_pci"
"ahci"
"usbhid"
"usb_storage"
"sd_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
@@ -25,7 +37,10 @@
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/357E-BCCD";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
options = [
"fmask=0077"
"dmask=0077"
];
};
fileSystems."/home" = {
@@ -44,6 +59,5 @@
# networking.interfaces.wlp11s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View File

@@ -1,10 +1,18 @@
{ host, pkgs, self, inputs, lib, username, config, ... }: {
{
host,
pkgs,
self,
inputs,
lib,
username,
config,
...
}:
{
home.username = "${username}";
home.homeDirectory =
"/home/${username}";
home.stateVersion =
"24.05";
home.homeDirectory = "/home/${username}";
home.stateVersion = "24.05";
programs.home-manager.enable = true;

View File

@@ -1,4 +1,9 @@
{ inputs, pkgs, username, ... }:
{
inputs,
pkgs,
username,
...
}:
let
shed = inputs.shed.packages.${pkgs.stdenv.hostPlatform.system}.default;
@@ -33,8 +38,14 @@ in
};
environment = {
variables = { PATH = "${pkgs.clang-tools}/bin:$PATH"; };
shells = [ pkgs.myPkgs.slash pkgs.zsh pkgs.bash ];
variables = {
PATH = "${pkgs.clang-tools}/bin:$PATH";
};
shells = [
pkgs.myPkgs.slash
pkgs.zsh
pkgs.bash
];
};
programs.shed.enable = true;
@@ -52,7 +63,13 @@ in
isNormalUser = true;
initialPassword = "1234";
shell = pkgs.shed;
extraGroups = [ "davfs2" "input" "wheel" "persist" "libvirtd" ];
extraGroups = [
"davfs2"
"input"
"wheel"
"persist"
"libvirtd"
];
};
};
};

View File

@@ -1,4 +1,9 @@
{ slash, pkgs, username, ... }:
{
slash,
pkgs,
username,
...
}:
let
kickstartServer =
@@ -17,30 +22,31 @@ let
'';
};
startTf2Server = pkgs.writeShellScript "start-srv.sh" ''
set -euo pipefail
export HOME=/home/tf2
export LD_LIBRARY_PATH=/usr/lib:/usr/lib32
mkdir -p "$HOME/tf2server"
mkdir -p "$HOME/tf2server"
set -euo pipefail
export HOME=/home/tf2
export LD_LIBRARY_PATH=/usr/lib:/usr/lib32
mkdir -p "$HOME/tf2server"
mkdir -p "$HOME/tf2server"
steamcmd +force_install_dir "$HOME/tf2server" \
+login anonymous \
+app_update 232250 validate \
+quit
steamcmd +force_install_dir "$HOME/tf2server" \
+login anonymous \
+app_update 232250 validate \
+quit
cd "$HOME/tf2server"
cd "$HOME/tf2server"
ln -sf "$HOME/.steam/steam/linux64" "$HOME/.steam/sdk64"
ln -sf "$HOME/.steam/steam/linux32" "$HOME/.steam/sdk32"
ln -sf "$HOME/.steam/steam/linux64" "$HOME/.steam/sdk64"
ln -sf "$HOME/.steam/steam/linux32" "$HOME/.steam/sdk32"
exec ./srcds_run -game tf -console -port 25565 +map cp_dustbowl \
+ip 10.233.1.2 -norestart \
+sv_setsteamaccount 8862FD4B30F401036B8AAC6A7FE6B123
exec ./srcds_run -game tf -console -port 25565 +map cp_dustbowl \
+ip 10.233.1.2 -norestart \
+sv_setsteamaccount 8862FD4B30F401036B8AAC6A7FE6B123
'';
in
pkgs.buildFHSEnv {
name = "srcds-env";
targetPkgs = pkgs: with pkgs; [
pkgs.buildFHSEnv {
name = "srcds-env";
targetPkgs =
pkgs: with pkgs; [
steamcmd
glibc
zlib
@@ -50,29 +56,30 @@ let
libnl
libsrcds
# Optional: link compat
stdenv.cc.cc.lib
];
multiPkgs = pkgs: with pkgs.pkgsi686Linux; [
glibc
zlib
ncurses5
libuuid
alsa-lib
libxcrypt-legacy
gcc
];
multiArch = true;
runScript = "${startTf2Server}";
# Optional: link compat
stdenv.cc.cc.lib
];
multiPkgs =
pkgs: with pkgs.pkgsi686Linux; [
glibc
zlib
ncurses5
libuuid
alsa-lib
libxcrypt-legacy
gcc
];
multiArch = true;
runScript = "${startTf2Server}";
};
};
in
{
networking = {
nat = {
enable = true;
internalInterfaces = ["ve-+"];
externalInterface = "enp8s0";
internalInterfaces = [ "ve-+" ];
externalInterface = "enp8s0";
};
};
containers.tf2server = {
@@ -84,7 +91,6 @@ in
imports = [ ];
nixpkgs.config.allowUnfree = true;
services.openssh.enable = true;
users.users.root.password = "root"; # For quick login, remove in prod
@@ -114,11 +120,19 @@ in
};
};
nix.settings.experimental-features = [ "nix-command" "flakes" ];
nix.settings.experimental-features = [
"nix-command"
"flakes"
];
# Optional: open ports on the container
networking.firewall.allowedTCPPorts = [ 25565 ];
networking.firewall.allowedUDPPorts = [ 25565 27005 27015 27020 ];
networking.firewall.allowedUDPPorts = [
25565
27005
27015
27020
];
system.stateVersion = "25.11"; # or your NixOS version
};

View File

@@ -1,41 +1,68 @@
# 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, pkgs, modulesPath, ... }:
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "ahci" "uas" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.availableKernelModules = [
"xhci_pci"
"nvme"
"ahci"
"uas"
"usbhid"
"usb_storage"
"sd_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/9a98748d-1953-4316-9788-07d11c5d0af6";
fsType = "btrfs";
options = [ "subvol=root" "compress=zstd:3" "noatime" ];
};
fileSystems."/" = {
device = "/dev/disk/by-uuid/9a98748d-1953-4316-9788-07d11c5d0af6";
fsType = "btrfs";
options = [
"subvol=root"
"compress=zstd:3"
"noatime"
];
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/5BA1-A9F8";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/5BA1-A9F8";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
};
fileSystems."/home" =
{ device = "/dev/disk/by-uuid/00fd7a7c-d916-4a61-abc1-8dde26b4413b";
fsType = "btrfs";
options = [ "compress=zstd:3" "noatime" ];
};
fileSystems."/home" = {
device = "/dev/disk/by-uuid/00fd7a7c-d916-4a61-abc1-8dde26b4413b";
fsType = "btrfs";
options = [
"compress=zstd:3"
"noatime"
];
};
fileSystems."/nix" =
{ device = "/dev/disk/by-uuid/7c03499c-e2a7-4352-8797-a21f094ef90b";
fsType = "btrfs";
options = [ "compress=zstd:3" "noatime" ];
};
fileSystems."/nix" = {
device = "/dev/disk/by-uuid/7c03499c-e2a7-4352-8797-a21f094ef90b";
fsType = "btrfs";
options = [
"compress=zstd:3"
"noatime"
];
};
swapDevices = [ ];

View File

@@ -1,7 +1,7 @@
{ username, ... }: {
{ username, ... }:
{
home.username = "${username}";
home.homeDirectory =
"/home/${username}";
home.homeDirectory = "/home/${username}";
home.stateVersion = "25.05";
programs.home-manager.enable = true;
@@ -14,7 +14,10 @@
envConfig = {
hyprlandConfig = {
enable = true;
monitorNames = [ "DP-3" "DP-1" ];
monitorNames = [
"DP-3"
"DP-1"
];
workspaceLayout = "dualmonitor";
};
userPkgs.enable = true;