This commit is contained in:
2025-05-15 21:11:30 +03:00
commit b6cee5e832
43 changed files with 2652 additions and 0 deletions
Executable
+1
View File
@@ -0,0 +1 @@
I'm a super newbie who just put my goodies here
+38
View File
@@ -0,0 +1,38 @@
{
disko.devices = {
disk = {
main = {
device = "/dev/mmcblk0";
type = "disk";
content = {
type = "gpt";
partitions = {
ESP = {
type = "EF00";
size = "512M";
content = {
type = "filesystem";
format = "vfat";
mountpoint = "/boot";
};
};
swap = {
size = "2G";
content = {
type = "swap";
};
};
root = {
size = "100%";
content = {
type = "filesystem";
format = "ext4";
mountpoint = "/";
};
};
};
};
};
};
};
}
+59
View File
@@ -0,0 +1,59 @@
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot = {
initrd = {
availableKernelModules = [
"nvme"
"xhci_pci"
"usbhid"
"usb_storage"
"uas"
"sd_mod"
];
kernelModules = [ ];
};
kernelModules = [ "kvm-amd" ];
extraModulePackages = [ ];
};
fileSystems = {
"/" = {
device = "/dev/disk/by-uuid/5938c796-6ff5-49d9-a3a6-022b4c32beeb";
fsType = "ext4";
};
"/boot" = {
device = "/dev/disk/by-uuid/61BF-3342";
fsType = "vfat";
options = [
"fmask=0077"
"dmask=0077"
];
};
};
swapDevices = [
{ device = "/dev/disk/by-uuid/d89bccd2-0672-4855-9d87-40e2688cdec4"; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp2s0.useDHCP = lib.mkDefault true;
# networking.interfaces.tailscale0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}
+14
View File
@@ -0,0 +1,14 @@
{
config,
...
}:
{
hardware = {
logitech = {
wireless = {
enable = true;
enableGraphical = true;
};
};
};
}
+78
View File
@@ -0,0 +1,78 @@
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot = {
initrd = {
availableKernelModules = [
"ahci"
"xhci_pci"
"usbhid"
"usb_storage"
"sd_mod"
"sdhci_pci"
];
};
kernel = {
sysctl = {
"fs.inotify.max_user_watches" = "204800";
};
};
kernelModules = [
"kvm-intel"
"coretemp"
];
};
fileSystems = {
"/" = {
device = "/dev/disk/by-partlabel/disk-main-root";
fsType = "ext4";
};
"/boot" = {
device = "/dev/disk/by-partlabel/disk-main-ESP";
fsType = "vfat";
options = [
"fmask=0022"
"dmask=0022"
];
};
};
# fileSystems."/" =
# { device = "/dev/disk/by-uuid/8acccc34-edc6-4934-886c-ef4b778ca24a";
# fsType = "ext4";
# };
#
# fileSystems."/boot" =
# { device = "/dev/disk/by-uuid/DDF2-C940";
# fsType = "vfat";
# options = [ "fmask=0022" "dmask=0022" ];
# };
#
# fileSystems."/home/otreca/External" =
# { device = "/dev/disk/by-uuid/37e53ebc-5343-a94d-9fe2-0ca39e13a8de";
# fsType = "ext4";
# };
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.eno1.useDHCP = lib.mkDefault true;
# networking.interfaces.tailscale0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}
+169
View File
@@ -0,0 +1,169 @@
{
inputs,
...
}@flakeContext:
let
nixosModule =
{
config,
lib,
pkgs,
...
}:
{
imports =
with inputs;
[
./hardware/laptop.nix
./hardware/logitech.nix
self.nixosModules.default
nixos-hardware.nixosModules.asus-fa506ic
self.nixosModules.software.wine
self.nixosModules.desktop
self.homeConfigurations.main.nixosModule
self.homeConfigurations.root.nixosModule
]
++ builtins.attrValues inputs.self.nixosModules.extra.self;
fileSystems = {
"${inputs.zeroq.dirs.therima-drive}" = {
device = "/dev/disk/by-uuid/C0A2DDEFA2DDEA44";
fsType = "ntfs3";
options = [
"defaults"
"uid=1000"
"gid=1000"
"fmask=0007"
"dmask=0007"
"nofail"
"x-systemd.device-timeout=0"
];
};
"${inputs.zeroq.dirs.vetymae-drive}" = {
device = "/dev/disk/by-uuid/6E04EA7F04EA49A3";
fsType = "ntfs3";
options = [
"defaults"
"uid=1000"
"gid=1000"
"fmask=0007"
"dmask=0007"
"nofail"
"x-systemd.device-timeout=0"
];
};
};
boot = {
kernelPackages = lib.mkDefault pkgs.linuxPackages_xanmod_stable;
loader = {
systemd-boot.enable = lib.mkDefault true;
efi.canTouchEfiVariables = lib.mkDefault true;
};
};
hardware = {
bluetooth.enable = true;
# nvidia = {
# open = true;
# dynamicBoost.enable = true;
# nvidiaSettings = true;
# powerManagement = {
# enable = false;
# finegrained = false; # maybe comment this out idk what it does
# };
# #package = config.boot.kernelPackages.nvidiaPackages.stable;
# nvidiaPersistenced = true;
# modesetting.enable = true;
# prime = {
# offload = {
# enable = true;
# enableOffloadCmd = true;
# };
# sync.enable = false;
# amdgpuBusId = "PCI:6:0:0";
# nvidiaBusId = "PCI:1:0:0";
# };
# };
};
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
networking = {
hostName = "${inputs.zeroq.devices.laptop.hostname}";
networkmanager.enable = true;
firewall.enable = false;
};
i18n = {
extraLocaleSettings = {
LC_ADDRESS = "ru_RU.UTF-8";
LC_IDENTIFICATION = "ru_RU.UTF-8";
LC_MEASUREMENT = "ru_RU.UTF-8";
LC_MONETARY = "ru_RU.UTF-8";
LC_NAME = "ru_RU.UTF-8";
LC_NUMERIC = "ru_RU.UTF-8";
LC_PAPER = "ru_RU.UTF-8";
LC_TELEPHONE = "ru_RU.UTF-8";
LC_TIME = "ru_RU.UTF-8";
};
};
services = {
xserver = {
videoDrivers = [
"amdgpu"
"nvidia"
];
};
syncthing = {
enable = true;
systemService = true;
configDir = "${inputs.zeroq.dirs.user-storage}/Syncthing/${config.system.name}"; # ${inputs.zeroq.devices.laptop.hostname}
dataDir = "${inputs.zeroq.dirs.user-home}";
group = "users";
user = "${inputs.zeroq.devices.admin}";
};
pipewire = {
enable = lib.mkDefault true;
systemWide = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
jack.enable = true;
extraConfig.pipewire = {
"99-default.conf" = {
"context.properties" = {
"default.clock.rate" = 96000;
"default.clock.allowed-rates" = [
44100
48000
96000
];
"default.clock.quantum" = 256;
"default.clock.min-quantum" = 64;
"default.clock.max-quantum" = 1024;
};
};
};
};
thermald.enable = true;
earlyoom.enable = true;
preload.enable = true;
};
security = {
rtkit.enable = true;
};
system.stateVersion = "25.05";
};
in
inputs.nixpkgs.lib.nixosSystem {
modules = [
nixosModule
inputs.sops-nix.nixosModules.sops
];
system = "x86_64-linux";
}
+31
View File
@@ -0,0 +1,31 @@
{
inputs,
...
}@flakeContext:
let
nixosModule =
{
config,
lib,
pkgs,
...
}:
{
system.nixos.label = "stock";
imports = with inputs; [
self.nixosModules.default
nixos-hardware.nixosModules.chuwi-minibook-x
home-manager.nixosModules.home-manager # home-manager module
self.homeConfigurations.oqyude.nixosModule # home-manager configuration module
];
hardware.intel-gpu-tools.enable = true;
};
in
inputs.nixpkgs.lib.nixosSystem {
modules = with inputs; [
nixosModule
];
system = "x86_64-linux";
}
+274
View File
@@ -0,0 +1,274 @@
{ inputs, ... }@flakeContext:
let
nixosModule =
{
config,
lib,
pkgs,
...
}:
{
imports = with inputs; [
./hardware/server.nix
self.nixosModules.default
self.homeConfigurations.server.nixosModule # home-manager configuration module
];
boot = {
kernelPackages = pkgs.linuxPackages_xanmod_stable;
hardwareScan = true;
loader = {
systemd-boot.enable = lib.mkDefault true;
efi.canTouchEfiVariables = lib.mkDefault true;
};
};
hardware = {
bluetooth.enable = false;
};
#swapDevices =
# [ { device = "/dev/disk/by-partlabel/disk-main-swap"; }
# ];
users = {
users = {
"${inputs.zeroq.devices.admin}" = {
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKduJia+unaQQdN6X5syaHvnpIutO+yZwvfiCP4qKQ/P root@sapphira"
];
};
};
};
fileSystems = {
# External drive
"${inputs.zeroq.dirs.server-home}" = {
device = "/dev/disk/by-uuid/37e53ebc-5343-a94d-9fe2-0ca39e13a8de";
fsType = "ext4";
options = [
"nofail"
"x-systemd.device-timeout=0"
];
};
};
services = {
nextcloud = {
enable = false;
package = pkgs.nextcloud30;
hostName = "localhost:10000";
database.createLocally = true;
config = {
dbtype = "mysql";
dbuser = "nextcloud";
#dbhost = "/run/postgresql";
dbname = "nextcloud";
adminuser = "root";
#adminpassFile = "${inputs.zeroq.dirs.credentials-target}/nextcloud/admin-pass.txt";
};
settings = {
appstoreEnable = false;
log_type = "file";
trusted_domains = [
"100.64.0.0"
"192.168.1.18"
"localhost"
];
};
extraAppsEnable = true;
extraApps = {
inherit (pkgs.nextcloud30Packages.apps)
bookmarks
calendar
contacts
cookbook
cospend
deck
end_to_end_encryption
forms
gpoddersync
groupfolders
impersonate
integration_paperless
mail
maps
memories
music
notes
notify_push
onlyoffice
polls
previewgenerator
richdocuments
spreed
tasks
user_oidc
user_saml
whiteboard
;
};
};
earlyoom.enable = true;
preload.enable = true;
auto-cpufreq.enable = true;
throttled.enable = true;
nginx = {
enable = false;
recommendedGzipSettings = true;
recommendedOptimisation = true;
recommendedProxySettings = true;
recommendedTlsSettings = true;
virtualHosts = {
"localhost:10000" = {
forceSSL = false;
enableACME = false;
listen = [
{
addr = "100.64.0.0";
port = 10000;
}
{
addr = "192.168.1.18";
port = 10000;
}
];
};
};
};
postgresql = {
enable = false;
# ensureDatabases = [ "nextcloud" ];
# ensureUsers = [
# {
# name = "nextcloud"; # Здесь не хватает строчек\\
# }
# ];
};
journald = {
extraConfig = ''
SystemMaxUse=128M
'';
};
samba = {
enable = true;
settings = {
global = {
"invalid users" = [ ];
"passwd program" = "/run/wrappers/bin/passwd %u";
security = "user";
};
nixos = {
"path" = "/etc/nixos";
"browseable" = "yes";
"read only" = "no";
"valid users" = "${inputs.zeroq.devices.admin}";
"guest ok" = "no";
"writable" = "yes";
"create mask" = 644;
"directory mask" = 644;
"force user" = "root";
"force group" = "root";
};
root = {
"path" = "/";
"browseable" = "yes";
"read only" = "no";
"valid users" = "${inputs.zeroq.devices.admin}";
"guest ok" = "no";
"writable" = "yes";
#"create mask" = 0644;
#"directory mask" = 0644;
"force user" = "root";
"force group" = "root";
};
"${inputs.zeroq.devices.admin}" = {
"path" = "${inputs.zeroq.dirs.server-home}";
"browseable" = "yes";
"read only" = "no";
"valid users" = "${inputs.zeroq.devices.admin}";
"guest ok" = "no";
"writable" = "yes";
"create mask" = 700;
"directory mask" = 700;
"force user" = "${inputs.zeroq.devices.admin}";
"force group" = "users";
};
};
};
calibre-web = {
enable = true;
group = "users";
user = "${inputs.zeroq.devices.admin}";
options = {
calibreLibrary = "${inputs.zeroq.dirs.calibre-library}";
enableBookUploading = true;
enableKepubify = false;
};
listen.ip = "0.0.0.0";
listen.port = 8083;
openFirewall = true;
};
openssh = {
enable = true;
allowSFTP = true;
#knownHosts.otreca.publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJpMaD143EZqhRlpAgNINLrH/qXkN3zXmKgFJlhbhGwg";
hostKeys = [
{
path = "/etc/ssh/id_ed25519";
type = "ed25519";
}
];
settings = {
PasswordAuthentication = false;
PermitRootLogin = "yes";
UsePAM = true;
};
};
transmission = {
enable = true;
credentialsFile = "${inputs.zeroq.dirs.server-home}/server/transmission/settings.json";
openRPCPort = true;
package = pkgs.transmission_4;
user = "${inputs.zeroq.devices.admin}";
group = "users";
settings = {
download-dir = "${inputs.zeroq.dirs.server-home}/Downloads";
incomplete-dir = "${inputs.zeroq.dirs.server-home}/Downloads/Temp";
incomplete-dir-enabled = true;
rpc-bind-address = "0.0.0.0";
rpc-port = 9091;
rpc-whitelist-enabled = false;
umask = 0;
};
};
syncthing = {
enable = true;
systemService = true;
guiAddress = "0.0.0.0:8384";
configDir = "${inputs.zeroq.dirs.storage}/Syncthing/${inputs.zeroq.devices.server.hostname}";
dataDir = "${inputs.zeroq.dirs.server-home}";
group = "users";
user = "${inputs.zeroq.devices.admin}";
};
tailscale.enable = true;
};
networking = {
hostName = "${inputs.zeroq.devices.server.hostname}";
networkmanager.enable = true;
firewall.enable = false;
};
system = {
stateVersion = "25.05";
};
};
in
inputs.nixpkgs.lib.nixosSystem {
modules = with inputs; [
nixosModule
];
system = "x86_64-linux";
}
+77
View File
@@ -0,0 +1,77 @@
{ inputs, ... }@flakeContext:
let
nixosModule =
{
config,
lib,
pkgs,
modulesPath,
...
}:
{
imports = [ <nixos-wsl/modules> ];
i18n = {
defaultLocale = "en_US.UTF-8";
supportedLocales = [
"ru_RU.UTF-8/UTF-8"
"en_US.UTF-8/UTF-8"
];
};
networking.hostName = "${inputs.zeroq.devices.wsl.username}";
users = {
defaultUserShell = pkgs.zsh;
};
nixpkgs.config.allowUnfree = true;
nix.settings.experimental-features = [
"nix-command"
"flakes"
];
environment.systemPackages = with pkgs; [
btop
fastfetch
yazi
];
programs = {
lazygit.enable = true;
git.enable = true;
nh.enable = true;
zsh = {
enable = true;
enableCompletion = true;
enableBashCompletion = true;
syntaxHighlighting.enable = true;
zsh-autoenv.enable = true;
loginShellInit = "clear && fastfetch";
ohMyZsh = {
enable = true;
theme = "robbyrussell";
};
};
};
zramSwap.enable = true;
services.earlyoom.enable = true;
wsl = {
enable = true;
startMenuLaunchers = true;
#useWindowsDriver = true;
defaultUser = "nixos";
};
system.stateVersion = "24.05";
};
in
inputs.nixpkgs.lib.nixosSystem {
modules = [
nixosModule
];
system = "x86_64-linux";
}
Generated Executable
+536
View File
@@ -0,0 +1,536 @@
{
"nodes": {
"aagl": {
"inputs": {
"flake-compat": [
"flake-compat"
],
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1747088856,
"narHash": "sha256-zWSO9D3dUiLXQ6eY7sjFASLwsiH140AMORrJPm44DPI=",
"owner": "ezKEa",
"repo": "aagl-gtk-on-nix",
"rev": "3448880953fc93666096d1e2878799d07a6c04db",
"type": "github"
},
"original": {
"owner": "ezKEa",
"repo": "aagl-gtk-on-nix",
"type": "github"
}
},
"disko": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1746729224,
"narHash": "sha256-9R4sOLAK1w3Bq54H3XOJogdc7a6C2bLLmatOQ+5pf5w=",
"owner": "nix-community",
"repo": "disko",
"rev": "85555d27ded84604ad6657ecca255a03fd878607",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "disko",
"type": "github"
}
},
"flake-compat": {
"locked": {
"lastModified": 1747046372,
"narHash": "sha256-CIVLLkVgvHYbgI2UpXvIIBJ12HWgX+fjA8Xf8PUmqCY=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "9100a0f413b0c601e0533d1d94ffd501ce2e7885",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib"
},
"locked": {
"lastModified": 1743550720,
"narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "c621e8422220273271f52058f618c94e405bb0f5",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_2": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib_2"
},
"locked": {
"lastModified": 1743550720,
"narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "c621e8422220273271f52058f618c94e405bb0f5",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_3": {
"inputs": {
"nixpkgs-lib": [
"nur",
"nixpkgs"
]
},
"locked": {
"lastModified": 1733312601,
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"grub2-themes": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1734412921,
"narHash": "sha256-JeMqc7lLowKn6klrCcOkcOg38yNqF7MPbN4Elh6Xvq0=",
"owner": "vinceliuice",
"repo": "grub2-themes",
"rev": "f6ab2438e124f60a340a526543e498e5e33b3c53",
"type": "github"
},
"original": {
"owner": "vinceliuice",
"repo": "grub2-themes",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1747155932,
"narHash": "sha256-NnPzzXEqfYjfrimLzK0JOBItfdEJdP/i6SNTuunCGgw=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "8d832ddfda9facf538f3dda9b6985fb0234f151c",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"musnix": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1741303672,
"narHash": "sha256-eRKbKccBu3PK/oJpmUuLo+0v45d0SEjosE8tVsHbpeA=",
"owner": "musnix",
"repo": "musnix",
"rev": "d56a15f30329f304151e4e05fa82264d127da934",
"type": "github"
},
"original": {
"owner": "musnix",
"repo": "musnix",
"type": "github"
}
},
"nix-gaming": {
"inputs": {
"flake-parts": "flake-parts_2",
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1747101345,
"narHash": "sha256-IjktcMUVCez262VtDAh9U9FCs8Cur+yagZpcJzDwdFY=",
"owner": "fufexan",
"repo": "nix-gaming",
"rev": "3b8f27e4a0b894dedc07f398b5ef1a747861fea3",
"type": "github"
},
"original": {
"owner": "fufexan",
"repo": "nix-gaming",
"type": "github"
}
},
"nix-index-database": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1746934494,
"narHash": "sha256-3n6i+F0sDASjkhbvgFDpPDZGp7z19IrRtjfF9TwJpCA=",
"owner": "nix-community",
"repo": "nix-index-database",
"rev": "e9b21b01e4307176b9718a29ac514838e7f6f4ff",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nix-index-database",
"type": "github"
}
},
"nixos-hardware": {
"locked": {
"lastModified": 1747129300,
"narHash": "sha256-L3clA5YGeYCF47ghsI7Tcex+DnaaN/BbQ4dR2wzoiKg=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "e81fd167b33121269149c57806599045fd33eeed",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "master",
"repo": "nixos-hardware",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1746576598,
"narHash": "sha256-FshoQvr6Aor5SnORVvh/ZdJ1Sa2U4ZrIMwKBX5k2wu0=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b3582c75c7f21ce0b429898980eddbbf05c68e55",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-last-unstable": {
"locked": {
"lastModified": 1746269363,
"narHash": "sha256-Q0lKWway9OmZnkDTpAoAE9VLXHOHqCqdJ3N0tkSM99g=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b6aef6c3553f849e1e6c08f1bcd3061df2b69fc4",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b6aef6c3553f849e1e6c08f1bcd3061df2b69fc4",
"type": "github"
}
},
"nixpkgs-lib": {
"locked": {
"lastModified": 1743296961,
"narHash": "sha256-b1EdN3cULCqtorQ4QeWgLMrd5ZGOjLSLemfa00heasc=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "e4822aea2a6d1cdd36653c134cacfd64c97ff4fa",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixpkgs.lib",
"type": "github"
}
},
"nixpkgs-lib_2": {
"locked": {
"lastModified": 1743296961,
"narHash": "sha256-b1EdN3cULCqtorQ4QeWgLMrd5ZGOjLSLemfa00heasc=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "e4822aea2a6d1cdd36653c134cacfd64c97ff4fa",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixpkgs.lib",
"type": "github"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1746957726,
"narHash": "sha256-k9ut1LSfHCr0AW82ttEQzXVCqmyWVA5+SHJkS5ID/Jo=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "a39ed32a651fdee6842ec930761e31d1f242cb94",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-24.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1747060738,
"narHash": "sha256-ByfPRQuqj+nhtVV0koinEpmJw0KLzNbgcgi9EF+NVow=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "eaeed9530c76ce5f1d2d8232e08bec5e26f18ec1",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1747060738,
"narHash": "sha256-ByfPRQuqj+nhtVV0koinEpmJw0KLzNbgcgi9EF+NVow=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "eaeed9530c76ce5f1d2d8232e08bec5e26f18ec1",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nur": {
"inputs": {
"flake-parts": "flake-parts_3",
"nixpkgs": [
"nixpkgs"
],
"treefmt-nix": "treefmt-nix"
},
"locked": {
"lastModified": 1747151055,
"narHash": "sha256-zCGpF8BREFvzkSqgfEBgIcqtrnT8e9IqNQ3Zqe+OOk4=",
"owner": "nix-community",
"repo": "NUR",
"rev": "33dadfb985b667b866d1175a8519b7583a38ef63",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "NUR",
"type": "github"
}
},
"nypkgs": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1744125335,
"narHash": "sha256-yH1bbLTB/Ozhg7ScAXiJKzW1GZ4Y4+VlS9HCmIZDyME=",
"owner": "yunfachi",
"repo": "nypkgs",
"rev": "e9a5d894690e9205e28839ef9289ee2baa3f017c",
"type": "github"
},
"original": {
"owner": "yunfachi",
"repo": "nypkgs",
"type": "github"
}
},
"plasma-manager": {
"inputs": {
"home-manager": [
"home-manager"
],
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1742765550,
"narHash": "sha256-2vVIh2JrL6GAGfgCeY9e6iNKrBjs0Hw3bGQEAbwVs68=",
"owner": "nix-community",
"repo": "plasma-manager",
"rev": "b70be387276e632fe51232887f9e04e2b6ef8c16",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "plasma-manager",
"type": "github"
}
},
"root": {
"inputs": {
"aagl": "aagl",
"disko": "disko",
"flake-compat": "flake-compat",
"flake-parts": "flake-parts",
"flake-utils": "flake-utils",
"grub2-themes": "grub2-themes",
"home-manager": "home-manager",
"musnix": "musnix",
"nix-gaming": "nix-gaming",
"nix-index-database": "nix-index-database",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_2",
"nixpkgs-last-unstable": "nixpkgs-last-unstable",
"nixpkgs-stable": "nixpkgs-stable",
"nixpkgs-unstable": "nixpkgs-unstable",
"nur": "nur",
"nypkgs": "nypkgs",
"plasma-manager": "plasma-manager",
"sops-nix": "sops-nix",
"zapret": "zapret",
"zeroq": "zeroq"
}
},
"sops-nix": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1746485181,
"narHash": "sha256-PxrrSFLaC7YuItShxmYbMgSuFFuwxBB+qsl9BZUnRvg=",
"owner": "Mic92",
"repo": "sops-nix",
"rev": "e93ee1d900ad264d65e9701a5c6f895683433386",
"type": "github"
},
"original": {
"owner": "Mic92",
"repo": "sops-nix",
"type": "github"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"treefmt-nix": {
"inputs": {
"nixpkgs": [
"nur",
"nixpkgs"
]
},
"locked": {
"lastModified": 1733222881,
"narHash": "sha256-JIPcz1PrpXUCbaccEnrcUS8jjEb/1vJbZz5KkobyFdM=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "49717b5af6f80172275d47a418c9719a31a78b53",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "treefmt-nix",
"type": "github"
}
},
"zapret": {
"locked": {
"lastModified": 1745932796,
"narHash": "sha256-nbQNqqtLUF7FNg0FfT+V/qvRtTanSA4O3c3e/lto5oU=",
"owner": "oqyude",
"repo": "zapret-easyflake",
"rev": "dd2c75127343d08cf0a5fa8d15bdfe016d2691c5",
"type": "github"
},
"original": {
"owner": "oqyude",
"repo": "zapret-easyflake",
"type": "github"
}
},
"zeroq": {
"locked": {
"path": "./modules/zeroq",
"type": "path"
},
"original": {
"path": "./modules/zeroq",
"type": "path"
},
"parent": []
}
},
"root": "root",
"version": 7
}
Executable
+127
View File
@@ -0,0 +1,127 @@
{
description = "oqyude flake";
inputs = {
# My
zeroq.url = "path:./modules/zeroq"; # flake of variables
zapret.url = "github:oqyude/zapret-easyflake"; # stupid flake of zapret
# nixpkgs
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; # b6aef6c3553f849e1e6c08f1bcd3061df2b69fc4
nixpkgs-last-unstable.url = "github:NixOS/nixpkgs/b6aef6c3553f849e1e6c08f1bcd3061df2b69fc4"; # 507b63021ada5fee621b6ca371c4fca9ca46f52c
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-24.11";
# nix-community
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
flake-compat.url = "github:edolstra/flake-compat";
flake-utils.url = "github:numtide/flake-utils";
flake-parts.url = "github:hercules-ci/flake-parts";
nur = {
url = "github:nix-community/NUR";
inputs.nixpkgs.follows = "nixpkgs";
};
home-manager = {
url = "github:nix-community/home-manager"; # flake:home-manager
inputs.nixpkgs.follows = "nixpkgs";
};
disko = {
url = "github:nix-community/disko";
inputs.nixpkgs.follows = "nixpkgs";
};
plasma-manager = {
# https://github.com/nix-community/plasma-manager
url = "github:nix-community/plasma-manager";
inputs.nixpkgs.follows = "nixpkgs";
inputs.home-manager.follows = "home-manager";
};
nix-index-database = {
url = "github:nix-community/nix-index-database";
inputs.nixpkgs.follows = "nixpkgs";
};
# extras
nix-gaming.url = "github:fufexan/nix-gaming";
aagl = {
url = "github:ezKEa/aagl-gtk-on-nix";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-compat.follows = "flake-compat";
};
};
musnix = {
url = "github:musnix/musnix";
inputs.nixpkgs.follows = "nixpkgs";
};
grub2-themes = {
url = "github:vinceliuice/grub2-themes";
inputs.nixpkgs.follows = "nixpkgs";
};
nypkgs = {
# https://github.com/yunfachi/nypkgs
url = "github:yunfachi/nypkgs";
inputs.nixpkgs.follows = "nixpkgs";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
# stylix = {
# url = "github:danth/stylix";
# inputs = {
# nixpkgs.follows = "nixpkgs";
# home-manager.follows = "home-manager";
# flake-compat.follows = "flake-compat";
# flake-utils.follows = "flake-utils";
# };
# };
};
outputs =
inputs:
let
flakeContext = { inherit inputs; };
in
{
nixosConfigurations = {
atoridu = import ./devices/laptop.nix flakeContext; # atoridu
lamet = import ./devices/mini-laptop.nix flakeContext; # lamet
sapphira = import ./devices/server.nix flakeContext; # sapphira
wsl = import ./devices/wsl.nix flakeContext; # wsl
};
nixosModules = {
default = import ./modules/default.nix flakeContext;
desktop = import ./modules/desktop/default.nix flakeContext;
software = {
daw = import ./modules/software/daw.nix flakeContext;
virtual = import ./modules/software/virtual.nix flakeContext;
wine = import ./modules/software/wine.nix flakeContext;
};
extra = {
self = {
fingerprint = import ./modules/extra/self/fingerprint.nix flakeContext;
zapret = import ./modules/extra/self/zapret.nix flakeContext;
};
musnix = import ./modules/extra/musnix.nix flakeContext; # https://github.com/musnix/musnix
gaming = {
nix-gaming = import ./modules/extra/gaming/nix-gaming.nix flakeContext; # https://github.com/fufexan/nix-gaming
aagl = import ./modules/extra/gaming/aagl.nix flakeContext; # https://github.com/ezKEa/aagl-gtk-on-nix
};
};
};
homeConfigurations = {
root = import ./home/root.nix flakeContext;
main = import ./home/main.nix flakeContext;
server = import ./home/server.nix flakeContext;
};
homeModules = {
packages = import ./home/modules/packages.nix flakeContext;
default = import ./home/modules/default.nix flakeContext;
dconf = import ./home/modules/dconf.nix flakeContext;
beets = import ./home/modules/beets.nix flakeContext;
plasma-manager = import ./home/modules/plasma-manager.nix flakeContext;
};
};
}
Executable
+107
View File
@@ -0,0 +1,107 @@
{ inputs, ... }@flakeContext:
let
homeModule =
{
config,
lib,
pkgs,
...
}:
{
imports = [ ] ++ (builtins.attrValues inputs.self.homeModules);
xdg = {
enable = true;
autostart.enable = true;
configFile = {
"ludusavi" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.user-storage}/ludusavi/cfg";
target = "ludusavi";
};
"nekoray" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.user-storage}/Nekoray/${config.home.username}";
target = "nekoray";
};
"solaar" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.user-storage}/solaar";
target = "solaar";
};
"easyeffects" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.user-storage}/easyeffects";
target = "easyeffects";
};
"keepassxc" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.user-storage}/KeePassXC";
target = "keepassxc";
};
};
userDirs = {
enable = true;
createDirectories = true;
desktop = "${config.xdg.dataHome}/desktop";
documents = null;
download = "${config.home.homeDirectory}/Downloads";
music = "${config.home.homeDirectory}/Music";
pictures = "${config.home.homeDirectory}/Pictures";
publicShare = "${config.home.homeDirectory}/Misc/Public";
templates = null;
videos = "${config.home.homeDirectory}/Pictures/Videos";
};
};
home = {
username = "${inputs.zeroq.devices.admin}";
file = {
"ssh" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.user-storage}/SSH/${config.home.username}";
target = ".ssh";
};
"External" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.therima-drive}";
target = "External";
};
"Music" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.vetymae-drive}/Users/User/Music";
target = "Music";
};
"Pictures" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.vetymae-drive}/Users/User/Pictures";
target = "Pictures";
};
"Deploy" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.vetymae-drive}/Users/User/Deploy";
target = "Deploy";
};
"Misc" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.vetymae-drive}/Users/User/Misc";
target = "Misc";
};
};
};
};
nixosModule =
{ config, ... }:
{
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
users.${inputs.zeroq.devices.admin} = homeModule;
sharedModules = [ inputs.plasma-manager.homeManagerModules.plasma-manager ];
extraSpecialArgs = {
#inherit inputs;
inherit (config.networking) hostName;
};
};
};
in
(
(inputs.home-manager.lib.homeManagerConfiguration {
modules = [
homeModule
];
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
})
// {
inherit nixosModule;
}
)
+38
View File
@@ -0,0 +1,38 @@
{ inputs, ... }@flakeContext:
{
config,
pkgs,
...
}:
let
unstable = import inputs.nixpkgs-unstable { system = "x86_64-linux"; };
last-stable = import inputs.nixpkgs-last-unstable { system = "x86_64-linux"; };
in
{
dconf = {
settings = {
"org/virt-manager/virt-manager/connections" = {
autoconnect = [ "qemu:///system" ];
uris = [ "qemu:///system" ];
};
"org/gnome/shell" = {
disable-user-extensions = false;
enabled-extensions = with pkgs.gnomeExtensions; [
dash-to-panel.extensionUuid
arcmenu.extensionUuid
vitals.extensionUuid
appindicator.extensionUuid
];
disabled-extensions = [ ];
};
"org/gnome/desktop/interface" = {
color-scheme = "prefer-light";
enable-hot-corners = false;
};
};
};
home = {
packages = with pkgs; [
];
};
}
+13
View File
@@ -0,0 +1,13 @@
{ inputs, ... }@flakeContext:
{
config,
lib,
pkgs,
...
}:
{
home = {
stateVersion = lib.mkDefault "25.05";
homeDirectory = lib.mkDefault "/home/${config.home.username}";
};
}
+83
View File
@@ -0,0 +1,83 @@
{ inputs, ... }@flakeContext:
{
config,
pkgs,
...
}:
let
unstable = import inputs.nixpkgs-unstable { system = "x86_64-linux"; };
last-stable = import inputs.nixpkgs-last-unstable { system = "x86_64-linux"; };
stable = import inputs.nixpkgs-stable { system = "x86_64-linux"; };
in
{
programs = {
fastfetch.enable = true;
btop.enable = true;
mangohud.enable = true;
keepassxc.enable = true;
zed-editor = {
enable = true;
extensions = [
"nix"
];
userSettings = {
"telemetry" = {
"diagnostics" = false;
"metrics" = false;
};
"ui_font_size" = 20;
"buffer_font_size" = 26;
"theme" = {
"mode" = "system";
"light" = "Ayu Light";
"dark" = "Ayu Dark";
};
};
};
};
services = {
kdeconnect.enable = true;
easyeffects.enable = true;
};
home = {
packages = with pkgs; [
# Surfing
(brave.override {
commandLineArgs = [
"--password-store=basic" # on purpose to make it break "--password-store=gnome-libsecret"
];
})
nekoray
# Workflow
_64gram
discord
gramps
kdePackages.filelight
libreoffice-qt6
localsend
lollypop
obsidian
pdfarranger
stretchly
transmission_4-gtk
vlc
#zerotierone
#tg
#reaper
# Games
ludusavi
prismlauncher
lutris
# Libs
libsecret
# Display
#edid-decode
#displaycal
#argyllcms
];
};
}
+126
View File
@@ -0,0 +1,126 @@
{ inputs, ... }@flakeContext:
{
config,
pkgs,
...
}:
{
programs = {
kate = {
enable = true;
editor = {
brackets = {
automaticallyAddClosing = true;
highlightMatching = true;
};
font = {
family = "Hack";
pointSize = 14;
};
};
};
plasma = {
enable = true;
overrideConfig = false;
configFile = {
dolphinrc = {
"General" = {
"RememberOpenedTabs" = true;
};
"DetailsMode" = {
"ExpandableFolders" = false;
"PreviewSize" = 32;
"IconSize" = 32;
};
};
"katerc" = {
"KTextEditor View" = {
"Scroll Bar MiniMap" = false;
"Scroll Bar Preview" = false;
};
};
};
input = {
# /proc/bus/input/devices
mice = [
{
acceleration = -0.2;
accelerationProfile = "none";
enable = true;
leftHanded = false;
middleButtonEmulation = false;
name = "Logitech USB Receiver Mouse";
naturalScroll = false;
productId = "c548";
scrollSpeed = 1;
vendorId = "046d";
}
];
touchpads = [
{
accelerationProfile = "none";
disableWhileTyping = true;
enable = true;
leftHanded = true;
middleButtonEmulation = false;
name = "ELAN1203:00 04F3:307A Touchpad";
naturalScroll = true;
pointerSpeed = 0;
productId = "307a";
rightClickMethod = "bottomRight";
scrollMethod = "twoFingers";
tapDragLock = false;
tapToClick = true;
twoFingerTap = "rightClick";
vendorId = "04f3";
}
];
keyboard = {
switchingPolicy = "global";
# options = [
# "altshift"
# ];
layouts = [
{
layout = "us";
}
{
layout = "ru";
}
];
};
};
workspace = {
#clickItemTo = "open"; # If you liked the click-to-open default from plasma 5
lookAndFeel = "com.github.vinceliuice.WhiteSur-alt";
colorScheme = "WhiteSurAlt";
theme = "WhiteSur-Alt";
iconTheme = "WhiteSur";
cursor = {
theme = "Qogir";
size = 24;
};
#wallpaper = "${config.home.homeDirectory}//Misc/Desktops/Wallpapers/Desktop/END_Circle_7.png";
#windowDecorations = {
# library = "org.kde.kwin.aurorae";
# theme = "__aurorae__svg__WhiteSur";
#};
};
kwin = {
edgeBarrier = 0; # Disables the edge-barriers introduced in plasma 6.1
cornerBarrier = false;
#scripts.polonium.enable = true;
nightLight = {
enable = true;
mode = "constant";
temperature.night = 5800;
};
effects.shakeCursor.enable = false;
virtualDesktops = {
number = 2;
rows = 1;
};
};
};
};
}
Executable
+41
View File
@@ -0,0 +1,41 @@
{ inputs, ... }@flakeContext:
let
homeModule =
{
config,
lib,
pkgs,
...
}:
{
imports = with inputs; [
self.homeModules.default
self.homeModules.plasma-manager
];
home = {
username = "root";
homeDirectory = "/${config.home.username}";
};
};
nixosModule =
{ ... }:
{
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
users.root = homeModule;
sharedModules = [ inputs.plasma-manager.homeManagerModules.plasma-manager ];
};
};
in
(
(inputs.home-manager.lib.homeManagerConfiguration {
modules = [
homeModule
];
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
})
// {
inherit nixosModule;
}
)
+59
View File
@@ -0,0 +1,59 @@
{ inputs, ... }@flakeContext:
let
homeModule =
{
config,
lib,
pkgs,
...
}:
{
imports = [ inputs.self.homeModules.default ];
xdg = {
enable = true;
autostart.enable = true;
userDirs = {
enable = true;
createDirectories = false;
desktop = null;
documents = null;
download = null;
music = null;
pictures = null;
publicShare = null;
templates = null;
videos = null;
};
};
home = {
file = {
"ssh" = {
source = config.lib.file.mkOutOfStoreSymlink "${inputs.zeroq.dirs.storage}/SSH/${inputs.zeroq.devices.server.hostname}";
target = ".ssh";
};
};
username = "${inputs.zeroq.devices.admin}";
};
};
nixosModule =
{ ... }:
{
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
users.${inputs.zeroq.devices.admin} = homeModule;
};
};
in
(
(inputs.home-manager.lib.homeManagerConfiguration {
modules = [
homeModule
];
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
})
// {
inherit nixosModule;
}
)
+12
View File
@@ -0,0 +1,12 @@
{
imports = inputs.nypkgs.legacyPackages.${pkgs.system}.lib.umport {
path = ./.;
include = [
./somed4/somef3.nix
];
exclude = [
./somed4
./somef4.nix
];
};
}
+16
View File
@@ -0,0 +1,16 @@
{ inputs, ... }@flakeContext:
{
config,
lib,
...
}:
{
imports = [
./essentials
#./services
# Flake modules
inputs.home-manager.nixosModules.home-manager # home-manager module
inputs.nix-index-database.nixosModules.nix-index
];
}
+100
View File
@@ -0,0 +1,100 @@
# Setup DE, xserver and bootloader
{ inputs, ... }@flakeContext:
{
config,
lib,
pkgs,
...
}:
{
imports = [
./environment/kde.nix
#./environment/gnome.nix
#./environment/budgie.nix
#./environment/deepin.nix
./environment/theming.nix
inputs.grub2-themes.nixosModules.default # grub2 themes module
];
boot = {
plymouth = {
enable = true;
theme = "bgrt";
};
consoleLogLevel = 3; # Enable "Silent boot"
initrd.verbose = false;
kernelParams = [
"quiet"
"splash"
"boot.shell_on_fail"
"udev.log_priority=3"
"rd.systemd.show_status=auto"
];
loader = {
timeout = 2;
efi.canTouchEfiVariables = lib.mkForce false;
systemd-boot.enable = lib.mkForce false;
grub = {
enable = lib.mkForce true;
useOSProber = true;
efiInstallAsRemovable = true;
efiSupport = true;
device = "nodev";
};
grub2-theme = {
enable = true;
theme = "whitesur";
icon = "whitesur";
footer = true;
customResolution = "1920x1080"; # Optional: Set a custom resolution
};
};
};
hardware.graphics.enable = true;
programs = {
adb.enable = true;
dconf.enable = true;
gamemode.enable = true;
steam.enable = true;
xwayland.enable = true;
};
services = {
xserver = {
enable = true;
xkb = {
layout = "us,ru";
variant = "";
options = "grp:alt_shift_toggle";
};
};
libinput.enable = true;
colord.enable = true;
printing = {
enable = true;
cups-pdf.enable = true;
};
};
environment.sessionVariables = {
NIXOS_OZONE_WL = "1";
};
# environment = {
# systemPackages = with pkgs; [
# ];
# };
# systemd.services.xiccd = { # Color Profiler bus for x11
# enable = false;
# description = "Xiccd Screen Color Profiler";
# serviceConfig = {
# ExecStart = "${pkgs.xiccd}/bin/xiccd";
# ExecStop = "pkill xiccd";
# Restart = "always";
# };
# wantedBy = [ "dbus.service" ];
# after = [ "dbus.service" ];
# partOf = [ "dbus.service" ];
# };
}
+9
View File
@@ -0,0 +1,9 @@
{
config,
lib,
pkgs,
...
}:
{
services.xserver.windowManager.bspwm.enable = true;
}
+36
View File
@@ -0,0 +1,36 @@
{
config,
lib,
pkgs,
...
}:
{
services.xserver.displayManager.lightdm.enable = true;
#services.displayManager.defaultSession = "lomiri";
# services.xserver.desktopManager.budgie.enable = true;
#services.xserver.displayManager.lightdm.greeters.lomiri.enable= true;
#services.desktopManager.lomiri.enable = true;
#-services.xserver.desktopManager.mate.enable = true;
#-services.xserver.desktopManager.lxqt.enable = true;
# services.xserver.desktopManager.lumina.enable = true;
# services.xserver.desktopManager.cde.enable = true;
# services.xserver.desktopManager.cinnamon.enable = true;
# services.xserver.desktopManager.enlightenment.enable = true;
# services.desktopManager.cosmic.xwayland.enable = true;
# services.desktopManager.cosmic.enable = true;
# services.xserver = {
# enable = true;
# desktopManager = {
# #xterm.enable = false;
# xfce.enable = true;
# xfce.enableWaylandSession = true;
# };
# };
#- services.xserver.desktopManager.pantheon.enable = true;
#- services.pantheon.apps.enable = true;
}
+24
View File
@@ -0,0 +1,24 @@
{
config,
lib,
pkgs,
...
}:
{
# services.xserver = {
# enable = true;
# desktopManager = {
# #xterm.enable = false;
# xfce.enable = true;
# };
# };
services.xserver.displayManager.lightdm.enable = true;
services.xserver.desktopManager.deepin.enable = true;
services.deepin.deepin-anything.enable = true;
services.deepin.dde-daemon.enable = true;
services.deepin.dde-api.enable = true;
services.deepin.app-services.enable = true;
}
+43
View File
@@ -0,0 +1,43 @@
{
config,
lib,
pkgs,
...
}:
{
programs.dconf.enable = true;
environment = {
gnome.excludePackages = with pkgs; [
cheese # webcam tool
epiphany # web browser
#evince # document viewer
geary # email reader
gnome-characters
gnome-music
gnome-user-docs
gnome-tour
];
systemPackages = with pkgs; [
gnomeExtensions.appindicator
gnomeExtensions.dash-to-panel
gnomeExtensions.arcmenu
gnomeExtensions.vitals
gnomeExtensions.user-themes
gnome-tweaks
dconf-editor
dconf2nix
gnome-color-manager
];
};
services = {
udev.packages = with pkgs; [ gnome-settings-daemon ];
xserver = {
displayManager.gdm = {
enable = true;
wayland = true;
};
desktopManager.gnome.enable = true;
};
};
}
+33
View File
@@ -0,0 +1,33 @@
{
config,
lib,
pkgs,
...
}:
{
qt = {
enable = true;
style = "breeze";
platformTheme = "kde6"; # kde6
};
environment.plasma6.excludePackages = with pkgs.kdePackages; [
plasma-browser-integration
elisa
# kwallet
# kwallet-pam
# kwalletmanager
];
services = {
displayManager = {
sddm = {
enable = true;
theme = "WhiteSur-light";
wayland = {
enable = true;
compositor = "kwin";
};
};
};
desktopManager.plasma6.enable = true;
};
}
+19
View File
@@ -0,0 +1,19 @@
{
config,
lib,
pkgs,
...
}:
{
environment = {
systemPackages = with pkgs; [
whitesur-gtk-theme
whitesur-icon-theme
#whitesur-cursors
whitesur-kde
qogir-icon-theme
#qogir-theme
#qogir-kde
];
};
}
+14
View File
@@ -0,0 +1,14 @@
{
config,
...
}:
{
imports = [
./packages.nix
./programs.nix
./services.nix
./settings.nix
./tty.nix
./users.nix
];
}
+50
View File
@@ -0,0 +1,50 @@
{
config,
pkgs,
...
}:
{
environment = {
systemPackages = with pkgs; [
# Nix
nixfmt-tree
nix-diff
# Base
mc
yazi
pciutils
smartmontools
efibootmgr
usbutils
# Data
wget
curl
rsync
fdupes
# Disk
gparted
parted
ntfs3g
exfatprogs # for gparted exfat support
# Archivers
rar
unzip
zstd
zip
xarchiver
# Net
ipset
iptables
nftables
# Monitoring
btop
fastfetch
];
};
}
+29
View File
@@ -0,0 +1,29 @@
{
config,
...
}:
{
programs = {
git = {
enable = true;
config = {
user = {
name = "oqyude";
email = "oqyude@gmail.com";
};
};
};
lazygit.enable = true;
command-not-found.enable = false;
nix-index.enable = true;
nh = {
enable = true;
flake = "/etc/nixos";
clean = {
enable = true;
extraArgs = "--keep 3 --keep-since 2d";
dates = "daily";
};
};
};
}
+9
View File
@@ -0,0 +1,9 @@
{
config,
...
}:
{
services = {
tailscale.enable = true;
};
}
+50
View File
@@ -0,0 +1,50 @@
{
config,
...
}:
{
system.nixos.label = "default";
nix = {
settings = {
substituters = [
"https://nixos-cache-proxy.cofob.dev" # https://gist.github.com/cofob/9b1fd205e6d961a45c225ae9f0af1394
"https://nix-community.cachix.org"
];
auto-optimise-store = true;
experimental-features = [
"nix-command"
"flakes"
];
};
};
nixpkgs.config.allowUnfree = true;
security = {
sudo.wheelNeedsPassword = false;
polkit = {
enable = true;
extraConfig = ''
polkit.addRule(function(action, subject) {
if ((action.id == "org.gnome.gparted" || // for gnome
action.id == "org.freedesktop.policykit.exec") && // for desktop, nekoray
subject.isInGroup("wheel")){ // for sudo
return polkit.Result.YES;
}
});
'';
};
};
systemd.network.wait-online.enable = false;
time.timeZone = "Europe/Moscow";
i18n = {
defaultLocale = "en_US.UTF-8";
supportedLocales = [
#"C.UTF-8/UTF-8"
"en_US.UTF-8/UTF-8"
"ru_RU.UTF-8/UTF-8"
];
};
}
+37
View File
@@ -0,0 +1,37 @@
{
config,
pkgs,
...
}:
{
system.userActivationScripts.zshrc = "touch .zshrc";
users.defaultUserShell = pkgs.zsh;
programs.zsh = {
enable = true;
enableCompletion = true;
enableBashCompletion = true;
syntaxHighlighting.enable = true;
zsh-autoenv.enable = true;
histSize = 10000;
loginShellInit = "cd /etc/nixos && clear && fastfetch";
ohMyZsh = {
enable = true;
theme = "robbyrussell";
};
shellAliases = {
# shell
ff = "clear && fastfetch";
l = "ls -l";
# ssh
s-1 = "ssh sapphira-1";
s-1t = "ssh sapphira-1t";
# Somethings
reboot-bios = "sudo systemctl reboot --firmware-setup";
# Extras
plasma-manager = "nix run github:nix-community/plasma-manager";
};
};
}
+25
View File
@@ -0,0 +1,25 @@
{
config,
...
}:
{
users = {
users = {
oqyude = {
isNormalUser = true;
description = "Jor Oqyude";
initialPassword = "1234";
extraGroups = [
"audio"
"disk"
"gamemode"
"libvirtd"
"networkmanager"
"pipewire"
"qemu-libvirtd"
"wheel"
];
};
};
};
}
+19
View File
@@ -0,0 +1,19 @@
# https://github.com/ezKEa/aagl-gtk-on-nix
{ inputs, ... }@flakeContext:
{
config,
pkgs,
...
}:
{
imports = [ inputs.aagl.nixosModules.default ];
nix.settings = inputs.aagl.nixConfig; # Set up Cachix
programs = {
anime-game-launcher.enable = true;
#anime-games-launcher.enable = true;
#honkers-railway-launcher.enable = true;
#honkers-launcher.enable = true;
#wavey-launcher.enable = true;
#sleepy-launcher.enable = true;
};
}
+13
View File
@@ -0,0 +1,13 @@
# https://github.com/fufexan/nix-gaming
{ inputs, ... }@flakeContext:
{
config,
pkgs,
...
}:
{
nix.settings = {
substituters = [ "https://nix-gaming.cachix.org" ];
trusted-public-keys = [ "nix-gaming.cachix.org-1:nbjlureqMbRAxR1gJ/f3hxemL9svXaZF/Ees8vCUUs4=" ];
};
}
+47
View File
@@ -0,0 +1,47 @@
# https://github.com/musnix/musnix
{ inputs, ... }@flakeContext:
{
config,
lib,
pkgs,
...
}:
{
imports = [ inputs.musnix.nixosModules.musnix ];
specialisation = {
"rt_kernel" = {
inheritParentConfig = true;
configuration = {
###
boot.kernelModules = [
"snd-seq"
"snd-rawmidi"
];
services = {
pipewire.enable = lib.mkForce false;
jack = {
jackd.enable = lib.mkForce true;
alsa.enable = true;
loopback.enable = true;
};
};
environment.systemPackages = with pkgs; [
jack2
jack_capture
libjack2
pavucontrol
qjackctl
];
musnix = {
enable = true;
#ffado.enable = true;
rtcqs.enable = true;
kernel.realtime = true;
kernel.packages = pkgs.linuxPackages_latest_rt;
};
###
};
};
};
}
+33
View File
@@ -0,0 +1,33 @@
{ inputs, ... }@flakeContext:
let
pkgs-stable = import inputs.nixpkgs-stable { system = "x86_64-linux"; };
in
{
config,
pkgs,
...
}:
{
security.pam.services.login.fprintAuth = false;
services = {
fprintd = {
enable = true;
package = pkgs-stable.fprintd.override {
libfprint = pkgs-stable.libfprint.overrideAttrs (oldAttrs: {
version = "git";
src = pkgs-stable.fetchFromGitHub {
owner = "ericlinagora";
repo = "libfprint-CS9711";
rev = "c242a40fcc51aec5b57d877bdf3edfe8cb4883fd";
sha256 = "sha256-WFq8sNitwhOOS3eO8V35EMs+FA73pbILRP0JoW/UR80=";
};
nativeBuildInputs = oldAttrs.nativeBuildInputs ++ [
pkgs-stable.opencv
pkgs-stable.cmake
pkgs-stable.doctest
];
});
};
};
};
}
+30
View File
@@ -0,0 +1,30 @@
{ inputs, ... }@flakeContext:
{
config,
pkgs,
...
}:
{
systemd.services.zapret = {
description = "zapret complete";
unitConfig = {
After = [ "network-online.target" ];
Wants = [ "network-online.target" ];
};
wantedBy = [ "multi-user.target" ];
path = [ "/run/current-system/sw" ];
serviceConfig = {
Type = "simple";
Restart = "on-failure";
User = "root";
WorkingDirectory = "${inputs.zapret.script-dir}";
ExecStart = "/run/current-system/sw/bin/bash ./main_script.sh -nointeractive";
ExecStop = "/run/current-system/sw/bin/bash ./stop_and_clean_nft.sh";
};
};
environment = {
systemPackages = with pkgs; [
nftables
];
};
}
+21
View File
@@ -0,0 +1,21 @@
{ inputs, ... }@flakeContext:
{
config,
lib,
pkgs,
...
}:
{
environment = {
systemPackages = with pkgs; [
# yabridge
wineWowPackages.yabridge
yabridge
yabridgectl
# JACK Control
qjackctl
];
};
}
+52
View File
@@ -0,0 +1,52 @@
{ inputs, ... }@flakeContext:
{
config,
lib,
pkgs,
...
}:
{
boot = {
kernelModules = [
"kvm-amd"
"vfio"
"vfio-pci"
"vfio_iommu_type1"
"vfio_virqfd"
];
kernelParams = [
"amd_iommu=on"
"iommu=pt"
"kvm.ignore_msrs=1"
];
};
services = {
spice-vdagentd.enable = true;
};
virtualisation = {
libvirtd = {
enable = true;
onBoot = "ignore";
onShutdown = "shutdown";
qemu = {
swtpm.enable = true;
ovmf.enable = true;
ovmf.packages = [ pkgs.OVMFFull.fd ];
};
};
spiceUSBRedirection.enable = true;
};
environment = {
systemPackages = with pkgs; [
spice
#spice-gtk
#spice-protocol
virt-manager
virt-viewer
virtiofsd
win-spice
virtio-win
#looking-glass-client # pci-passthrough
];
};
}
+20
View File
@@ -0,0 +1,20 @@
{ inputs, ... }@flakeContext:
{
config,
lib,
pkgs,
...
}:
{
environment = {
systemPackages = with pkgs; [
#wineWowPackages.waylandFull
wineWowPackages.stagingFull
#wineWowPackages.fonts
dxvk
];
sessionVariables = {
WINEARCH = "win64";
};
};
}
+40
View File
@@ -0,0 +1,40 @@
{
description = "zeroq structure flake";
outputs =
{ self }:
rec {
nixos = "/etc/nixos";
devices = rec {
admin = "oqyude";
laptop = {
hostname = "atoridu";
};
mini-laptop = {
hostname = "lamet";
};
server = {
username = "otreca";
hostname = "sapphira";
};
wsl.hostname = "wsl";
};
dirs = rec {
# User
user-home = "/home/${devices.admin}";
user-storage = "${user-home}/Storage";
therima-drive = "/mnt/therima";
vetymae-drive = "/mnt/vetymae";
# Server
server-home = "/home/${devices.admin}/External";
storage = "${server-home}/Storage";
calibre-library = "${server-home}/Books-Library";
};
};
}