genesis
This commit is contained in:
commit
728d502eb0
38 changed files with 1070 additions and 0 deletions
5
.gitignore
vendored
Normal file
5
.gitignore
vendored
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
.directory
|
||||
*.swp
|
||||
result
|
||||
result-*
|
||||
|
||||
170
flake.lock
generated
Normal file
170
flake.lock
generated
Normal file
|
|
@ -0,0 +1,170 @@
|
|||
{
|
||||
"nodes": {
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1777699697,
|
||||
"narHash": "sha256-Eg9b/rq/ECYwNwEXs5i9wHyhxNI0JrYx2srdI2uZMaQ=",
|
||||
"ref": "refs/heads/main",
|
||||
"rev": "382052b74656a369c5408822af3f2501e9b1af81",
|
||||
"revCount": 94,
|
||||
"type": "git",
|
||||
"url": "https://git.lix.systems/lix-project/flake-compat.git"
|
||||
},
|
||||
"original": {
|
||||
"type": "git",
|
||||
"url": "https://git.lix.systems/lix-project/flake-compat.git"
|
||||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": "nixpkgs-lib"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1790898470,
|
||||
"narHash": "sha256-zTwuwezD0w3hpga6a6P8emidzAZFyWqlNeRBlpWOOl8=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "024633cd702b10285db5cb19b40ad48d2399ba60",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1792818383,
|
||||
"narHash": "sha256-199i7ubVSXTMl+0AAlL7cVCXSjcI+jWByMcimYjeMX0=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "24f2190587513b9c2f73db112a17844ae912d965",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "release-26.05",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"import-tree": {
|
||||
"locked": {
|
||||
"lastModified": 1788467110,
|
||||
"narHash": "sha256-ljEMTXP/rH0tOvDzc9gzwww6KcHRPRnEHzd9lK48V7s=",
|
||||
"owner": "vic",
|
||||
"repo": "import-tree",
|
||||
"rev": "eb1b52eaecc57f7c136d07ae8a93e724dfecac46",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "vic",
|
||||
"repo": "import-tree",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"mnw": {
|
||||
"locked": {
|
||||
"lastModified": 1784154424,
|
||||
"narHash": "sha256-HRn4O1X2ShYtbq5Egji72/aemyc2cIQicjRZD9hBqM8=",
|
||||
"owner": "Gerg-L",
|
||||
"repo": "mnw",
|
||||
"rev": "0151d9fa87992cbeb67c86616fb9170dcec830b6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Gerg-L",
|
||||
"repo": "mnw",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1792898606,
|
||||
"narHash": "sha256-Mg3rRjsbMqhSMxop5PYMXos8SwAjejrxSgVThTvP9eg=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "1f607aa79b6356ed45d3cd3c8079c196e79efa2c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-26.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-lib": {
|
||||
"locked": {
|
||||
"lastModified": 1790477367,
|
||||
"narHash": "sha256-oujbxmVKDhci2E4EM3KyAbRUgp5/IsCoiA/LfEF7OOk=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixpkgs.lib",
|
||||
"rev": "f7cd230690d9fc982d06129f9189b101fddcfa3b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "nixpkgs.lib",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-unstable": {
|
||||
"locked": {
|
||||
"lastModified": 1791260994,
|
||||
"narHash": "sha256-Miqqk/ammqnTUxaoCyvtwoPeLbI1ksFyLxi/CazZpWY=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "151fa4e8ddfdd8dd25d945ad94ed54a13de9f6e4",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "151fa4e8ddfdd8dd25d945ad94ed54a13de9f6e4",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nvf": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"mnw": "mnw",
|
||||
"nixpkgs": [
|
||||
"nixpkgs-unstable"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1792889789,
|
||||
"narHash": "sha256-xpH3z+T5NELixXRjxGJ3mx30kz63Xt2B0ZfPWl7hcUg=",
|
||||
"owner": "NotAShelf",
|
||||
"repo": "nvf",
|
||||
"rev": "557d2eb05a76e5939e6a75351343cae5731a71f8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NotAShelf",
|
||||
"repo": "nvf",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"flake-parts": "flake-parts",
|
||||
"home-manager": "home-manager",
|
||||
"import-tree": "import-tree",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||
"nvf": "nvf"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
||||
15
flake.nix
Normal file
15
flake.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
inputs = {
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
import-tree.url = "github:vic/import-tree";
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-26.05";
|
||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/151fa4e8ddfdd8dd25d945ad94ed54a13de9f6e4";
|
||||
home-manager.url = "github:nix-community/home-manager/release-26.05";
|
||||
nvf.url = "github:NotAShelf/nvf";
|
||||
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
nvf.inputs.nixpkgs.follows = "nixpkgs-unstable";
|
||||
};
|
||||
|
||||
outputs = inputs: inputs.flake-parts.lib.mkFlake {inherit inputs;} (inputs.import-tree ./modules);
|
||||
}
|
||||
17
modules/base/boot.nix
Normal file
17
modules/base/boot.nix
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
flake.modules.nixos.base = {pkgs, ...}: {
|
||||
boot = {
|
||||
loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
configurationLimit = 10;
|
||||
};
|
||||
|
||||
efi.canTouchEfiVariables = true;
|
||||
timeout = 2;
|
||||
};
|
||||
|
||||
kernelPackages = pkgs.linuxPackages_latest;
|
||||
};
|
||||
};
|
||||
}
|
||||
7
modules/base/configuration.nix
Normal file
7
modules/base/configuration.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
flake.modules.nixos.base = {modulesPath, ...}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
};
|
||||
}
|
||||
18
modules/base/doas.nix
Normal file
18
modules/base/doas.nix
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
flake.modules.nixos.base = {
|
||||
security = {
|
||||
doas = {
|
||||
enable = true;
|
||||
extraRules = [
|
||||
{
|
||||
groups = ["wheel"];
|
||||
keepEnv = true;
|
||||
persist = true;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
sudo.enable = false;
|
||||
};
|
||||
};
|
||||
}
|
||||
45
modules/base/fonts.nix
Normal file
45
modules/base/fonts.nix
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
{
|
||||
flake.modules.nixos.base = {pkgs, ...}: {
|
||||
fonts = {
|
||||
packages = with pkgs; [
|
||||
# GUI
|
||||
inter
|
||||
corefonts
|
||||
roboto
|
||||
cantarell-fonts
|
||||
# internationalisation
|
||||
noto-fonts
|
||||
noto-fonts-cjk-sans
|
||||
noto-fonts-cjk-serif
|
||||
noto-fonts-color-emoji
|
||||
noto-fonts-monochrome-emoji
|
||||
unifont
|
||||
unifont_upper
|
||||
unifont-csur
|
||||
# terminal
|
||||
nerd-fonts.iosevka
|
||||
];
|
||||
|
||||
fontconfig = {
|
||||
antialias = true;
|
||||
subpixel.rgba = "rgb";
|
||||
hinting.enable = true;
|
||||
defaultFonts = {
|
||||
serif = ["Noto Serif"];
|
||||
sansSerif = ["Cantarell"];
|
||||
monospace = ["Iosevka Nerd Font"];
|
||||
emoji = ["Noto Color Emoji"];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
flake.modules.nixos.kdePlasma = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
services.displayManager.sddm.settings.Theme.Font =
|
||||
lib.concatStrings config.fonts.fontconfig.defaultFonts.sansSerif;
|
||||
};
|
||||
}
|
||||
7
modules/base/locale.nix
Normal file
7
modules/base/locale.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
flake.modules.nixos.base = {
|
||||
time.timeZone = "Asia/Jakarta";
|
||||
i18n.defaultLocale = "en_GB.UTF-8";
|
||||
services.xserver.xkb.layout = "us";
|
||||
};
|
||||
}
|
||||
15
modules/base/nix-ld.nix
Normal file
15
modules/base/nix-ld.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
flake.modules.nixos.base = {pkgs, ...}: {
|
||||
programs.nix-ld = {
|
||||
enable = true;
|
||||
libraries = with pkgs; [
|
||||
fuse
|
||||
e2fsprogs
|
||||
stdenv.cc.cc
|
||||
zlib
|
||||
alsa-lib
|
||||
expat
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
18
modules/base/nix.nix
Normal file
18
modules/base/nix.nix
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
flake.modules.nixos.base = {
|
||||
nix = {
|
||||
settings = {
|
||||
experimental-features = ["nix-command" "flakes"];
|
||||
auto-optimise-store = true;
|
||||
};
|
||||
|
||||
gc = {
|
||||
automatic = true;
|
||||
dates = "weekly";
|
||||
options = "--delete-older-than 14d";
|
||||
};
|
||||
|
||||
optimise.automatic = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
8
modules/base/nixpkgs.nix
Normal file
8
modules/base/nixpkgs.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{self, ...}: {
|
||||
flake.modules.nixos.base = {
|
||||
# nixpkgs = {
|
||||
# config.allowUnfree = true;
|
||||
# overlays = [self.overlays.default];
|
||||
# };
|
||||
};
|
||||
}
|
||||
12
modules/base/overlays.nix
Normal file
12
modules/base/overlays.nix
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
{inputs, ...}: {
|
||||
perSystem = {
|
||||
pkgs,
|
||||
final,
|
||||
system,
|
||||
...
|
||||
}: {
|
||||
overlayAttrs = {
|
||||
unstable = import inputs.nixpkgs-unstable {inherit system;};
|
||||
};
|
||||
};
|
||||
}
|
||||
25
modules/base/programs.nix
Normal file
25
modules/base/programs.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
flake.modules.nixos.base = {
|
||||
programs = {
|
||||
fish.enable = true;
|
||||
|
||||
atuin = {
|
||||
enable = true;
|
||||
settings = {
|
||||
sync_address = "https://api.atuin.sh";
|
||||
enter_accept = true;
|
||||
};
|
||||
};
|
||||
|
||||
git = {
|
||||
enable = true;
|
||||
config = {
|
||||
init.defaultBranch = "main";
|
||||
advice.defaultBranchName = false;
|
||||
gpg.format = "ssh";
|
||||
commit.gpgSign = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
21
modules/base/services.nix
Normal file
21
modules/base/services.nix
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
flake.modules.nixos.base = {
|
||||
services = {
|
||||
fwupd.enable = true;
|
||||
locate.enable = true;
|
||||
openssh.enable = false;
|
||||
|
||||
pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
security.rtkit.enable = true;
|
||||
|
||||
# ssh-agent user service (SSH_AUTH_SOCK=%t/ssh-agent)
|
||||
programs.ssh.startAgent = true;
|
||||
};
|
||||
}
|
||||
39
modules/base/system-packages.nix
Normal file
39
modules/base/system-packages.nix
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
{
|
||||
flake.modules.nixos.base = {pkgs, ...}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
nh
|
||||
alejandra
|
||||
git
|
||||
unstable.python315
|
||||
# system utils
|
||||
file
|
||||
firmware-updater
|
||||
mtr
|
||||
gnupg
|
||||
ddate
|
||||
testdisk
|
||||
tree
|
||||
wget
|
||||
btop
|
||||
plocate
|
||||
traceroute
|
||||
rlwrap
|
||||
entr
|
||||
unzip
|
||||
ffmpeg
|
||||
imagemagick
|
||||
gnome-disk-utility
|
||||
# oxidised utils
|
||||
fd
|
||||
bat
|
||||
xh
|
||||
tlrc
|
||||
dysk
|
||||
dust
|
||||
hyperfine
|
||||
ripgrep
|
||||
fzf
|
||||
eza
|
||||
];
|
||||
};
|
||||
}
|
||||
8
modules/flake-parts.nix
Normal file
8
modules/flake-parts.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{inputs, ...}: {
|
||||
imports = [
|
||||
inputs.flake-parts.flakeModules.modules
|
||||
inputs.flake-parts.flakeModules.easyOverlay
|
||||
];
|
||||
|
||||
systems = [];
|
||||
}
|
||||
27
modules/gui/kde-plasma.nix
Normal file
27
modules/gui/kde-plasma.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
{
|
||||
flake.modules.nixos.kdePlasma = {pkgs, ...}: {
|
||||
services = {
|
||||
displayManager.sddm.enable = true;
|
||||
desktopManager.plasma6.enable = true;
|
||||
};
|
||||
|
||||
environment = {
|
||||
plasma6.excludePackages = with pkgs.kdePackages; [
|
||||
discover
|
||||
];
|
||||
|
||||
systemPackages = with pkgs.kdePackages; [
|
||||
kate
|
||||
elisa
|
||||
bluez-qt
|
||||
kalk
|
||||
filelight
|
||||
kamoso
|
||||
konversation
|
||||
kmail
|
||||
ktorrent
|
||||
kclock
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
9
modules/hosts/phostron/amd-microcode.nix
Normal file
9
modules/hosts/phostron/amd-microcode.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
};
|
||||
}
|
||||
21
modules/hosts/phostron/boot.nix
Normal file
21
modules/hosts/phostron/boot.nix
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {
|
||||
boot = {
|
||||
initrd = {
|
||||
availableKernelModules = [
|
||||
"nvme"
|
||||
"ehci_pci"
|
||||
"xhci_pci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
"sdhci_pci"
|
||||
];
|
||||
kernelModules = [];
|
||||
};
|
||||
|
||||
kernelModules = ["kvm-amd"];
|
||||
extraModulePackages = [];
|
||||
};
|
||||
};
|
||||
}
|
||||
32
modules/hosts/phostron/configuration.nix
Normal file
32
modules/hosts/phostron/configuration.nix
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
self,
|
||||
inputs,
|
||||
...
|
||||
}: let
|
||||
stateVersion = "26.05"; # i don't read comments!
|
||||
in {
|
||||
flake.modules.nixos.phostron = {lib, ...}: {
|
||||
system = {inherit stateVersion;};
|
||||
|
||||
networking.hostName = "phostron";
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
};
|
||||
|
||||
flake.modules.homeManager.coyote = {
|
||||
home = {inherit stateVersion;};
|
||||
};
|
||||
|
||||
flake.nixosConfigurations.phostron = inputs.nixpkgs.lib.nixosSystem {
|
||||
modules = [
|
||||
{
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nixpkgs.overlays = [self.overlays.default];
|
||||
}
|
||||
self.modules.nixos.base
|
||||
self.modules.nixos.phostron
|
||||
self.modules.nixos.kdePlasma
|
||||
self.modules.nixos.homeManagerModule
|
||||
self.modules.nixos.coyote
|
||||
];
|
||||
};
|
||||
}
|
||||
5
modules/hosts/phostron/display-manager.nix
Normal file
5
modules/hosts/phostron/display-manager.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
flake.modules.nixos.kdePlasma = {
|
||||
services.displayManager.sddm.settings.Theme.CursorSize = 18;
|
||||
};
|
||||
}
|
||||
19
modules/hosts/phostron/file-systems.nix
Normal file
19
modules/hosts/phostron/file-systems.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {
|
||||
fileSystems = {
|
||||
"/" = {
|
||||
device = "/dev/disk/by-uuid/24fb172c-c29f-40c3-ae4d-ff652358563a";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
"/boot" = {
|
||||
device = "/dev/disk/by-uuid/DFC9-994A";
|
||||
fsType = "vfat";
|
||||
options = ["fmask=0077" "dmask=0077"];
|
||||
};
|
||||
};
|
||||
|
||||
swapDevices = [{device = "/dev/disk/by-uuid/91d96247-85c3-4e0a-93a2-5632b96179b6";}];
|
||||
zramSwap.enable = true;
|
||||
};
|
||||
}
|
||||
9
modules/hosts/phostron/graphics.nix
Normal file
9
modules/hosts/phostron/graphics.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {
|
||||
hardware = {
|
||||
graphics.enable = true;
|
||||
graphics.enable32Bit = true;
|
||||
enableRedistributableFirmware = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
8
modules/hosts/phostron/networking.nix
Normal file
8
modules/hosts/phostron/networking.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {
|
||||
networking = {
|
||||
networkmanager.enable = true;
|
||||
firewall.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
13
modules/hosts/phostron/printing.nix
Normal file
13
modules/hosts/phostron/printing.nix
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {pkgs, ...}: {
|
||||
services.printing.enable = true;
|
||||
services.printing.drivers = with pkgs; [
|
||||
epson-escpr
|
||||
];
|
||||
|
||||
hardware.sane.enable = true;
|
||||
hardware.sane.extraBackends = with pkgs; [
|
||||
epsonscan2
|
||||
];
|
||||
};
|
||||
}
|
||||
5
modules/hosts/phostron/ssd.nix
Normal file
5
modules/hosts/phostron/ssd.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
flake.modules.nixos.phostron = {
|
||||
services.fstrim.enable = true;
|
||||
};
|
||||
}
|
||||
26
modules/modules/home-manager-nixos-module.nix
Normal file
26
modules/modules/home-manager-nixos-module.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{
|
||||
inputs,
|
||||
self,
|
||||
...
|
||||
}: {
|
||||
flake.modules.nixos.homeManagerModule = {
|
||||
imports = [inputs.home-manager.nixosModules.home-manager];
|
||||
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
backupFileExtension = "backup";
|
||||
users = {
|
||||
coyote = self.modules.homeManager.coyote;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
flake.modules.homeManager.coyote = {
|
||||
home = {
|
||||
username = "coyote";
|
||||
homeDirectory = "/home/coyote";
|
||||
shell.enableShellIntegration = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
29
modules/users/coyote/configuration.nix
Normal file
29
modules/users/coyote/configuration.nix
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
{
|
||||
flake.modules.nixos.coyote = {pkgs, ...}: {
|
||||
users = {
|
||||
users.coyote = {
|
||||
isNormalUser = true;
|
||||
description = "coyote";
|
||||
uid = 1000;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
"lp"
|
||||
"scanner"
|
||||
"video"
|
||||
"render"
|
||||
"input"
|
||||
"audio"
|
||||
"kvm"
|
||||
];
|
||||
};
|
||||
|
||||
mutableUsers = true;
|
||||
defaultUserShell = pkgs.fish;
|
||||
};
|
||||
|
||||
environment.sessionVariables = {
|
||||
NH_FLAKE = "/home/coyote/NixOS";
|
||||
};
|
||||
};
|
||||
}
|
||||
34
modules/users/coyote/home-packages.nix
Normal file
34
modules/users/coyote/home-packages.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {pkgs, ...}: {
|
||||
home.packages = with pkgs; [
|
||||
# internet
|
||||
vivaldi
|
||||
proton-vpn
|
||||
# productivity
|
||||
libreoffice-fresh
|
||||
karp
|
||||
keepassxc
|
||||
pdfarranger
|
||||
# multimedia
|
||||
vlc
|
||||
haruna
|
||||
subtitlecomposer
|
||||
kid3
|
||||
# music
|
||||
furnace
|
||||
corrscope
|
||||
unstable.audacity
|
||||
# editing
|
||||
kdePackages.kdenlive
|
||||
# games
|
||||
osu-lazer-bin
|
||||
pcsx2
|
||||
ppsspp
|
||||
# wine
|
||||
(unstable.bottles.override {removeWarningPopup = true;})
|
||||
# development
|
||||
emacs
|
||||
unstable.racket
|
||||
];
|
||||
};
|
||||
}
|
||||
92
modules/users/coyote/programs/fastfetch.nix
Normal file
92
modules/users/coyote/programs/fastfetch.nix
Normal file
|
|
@ -0,0 +1,92 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {pkgs, ...}: {
|
||||
programs.fastfetch = {
|
||||
enable = true;
|
||||
settings = {
|
||||
"$schema" = "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json";
|
||||
|
||||
logo = {
|
||||
type = "small";
|
||||
padding.top = 4;
|
||||
padding.left = 3;
|
||||
padding.right = 4;
|
||||
};
|
||||
|
||||
display.separator = " ";
|
||||
|
||||
modules = [
|
||||
{
|
||||
key = "╭─────────╮";
|
||||
type = "custom";
|
||||
}
|
||||
{
|
||||
key = "│ {#31}user {#keys}│";
|
||||
type = "title";
|
||||
format = "{user-name}";
|
||||
}
|
||||
{
|
||||
key = "│ {#32}host {#keys}│";
|
||||
type = "title";
|
||||
format = "{host-name}";
|
||||
}
|
||||
{
|
||||
key = "│ {#33}uptime {#keys}│";
|
||||
type = "uptime";
|
||||
}
|
||||
{
|
||||
key = "│ {#34}distro {#keys}│";
|
||||
type = "os";
|
||||
}
|
||||
{
|
||||
key = "│ {#35}kernel {#keys}│";
|
||||
type = "kernel";
|
||||
}
|
||||
{
|
||||
key = "│ {#36}desktop {#keys}│";
|
||||
type = "de";
|
||||
}
|
||||
{
|
||||
key = "│ {#31}term {#keys}│";
|
||||
type = "terminal";
|
||||
}
|
||||
{
|
||||
key = "│ {#32}shell {#keys}│";
|
||||
type = "shell";
|
||||
}
|
||||
{
|
||||
key = "│ {#33}cpu {#keys}│";
|
||||
type = "cpu";
|
||||
showPeCoreCount = true;
|
||||
}
|
||||
{
|
||||
key = "│ {#34}disk {#keys}│";
|
||||
type = "disk";
|
||||
folders = "/";
|
||||
}
|
||||
{
|
||||
key = "│ {#35}memory {#keys}│";
|
||||
type = "memory";
|
||||
}
|
||||
{
|
||||
key = "│ {#36}network {#keys}│";
|
||||
type = "localip";
|
||||
format = "{ipv4} ({ifname})";
|
||||
}
|
||||
{
|
||||
key = "├─────────┤";
|
||||
type = "custom";
|
||||
}
|
||||
{
|
||||
key = "│ {#39}colors {#keys}│";
|
||||
type = "colors";
|
||||
symbol = "circle";
|
||||
}
|
||||
{
|
||||
key = "╰─────────╯";
|
||||
type = "custom";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
23
modules/users/coyote/programs/git.nix
Normal file
23
modules/users/coyote/programs/git.nix
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {
|
||||
programs.git = {
|
||||
enable = true;
|
||||
settings = {
|
||||
user.name = "asnev";
|
||||
user.email = "notasnev@proton.me";
|
||||
};
|
||||
|
||||
signing = {
|
||||
key = "/home/coyote/.ssh/id_ed25519.pub";
|
||||
format = "ssh";
|
||||
};
|
||||
|
||||
includes = [
|
||||
{
|
||||
condition = "gitdir:/home/coyote/chitin/";
|
||||
contents.core.sshCommand = "ssh -i /home/coyote/.ssh/id_ed25519";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
190
modules/users/coyote/programs/nvf.nix
Normal file
190
modules/users/coyote/programs/nvf.nix
Normal file
|
|
@ -0,0 +1,190 @@
|
|||
{inputs, ...}: {
|
||||
flake.modules.homeManager.coyote = {pkgs, ...}: {
|
||||
imports = [inputs.nvf.homeManagerModules.default];
|
||||
|
||||
home.packages = with pkgs.unstable; [
|
||||
lazygit
|
||||
tree-sitter
|
||||
];
|
||||
|
||||
programs.nvf = {
|
||||
enable = true;
|
||||
defaultEditor = true;
|
||||
enableManpages = true;
|
||||
|
||||
settings.vim = {
|
||||
viAlias = true;
|
||||
vimAlias = true;
|
||||
|
||||
syntaxHighlighting = true;
|
||||
lineNumberMode = "relNumber";
|
||||
searchCase = "smart";
|
||||
hideSearchHighlight = false;
|
||||
|
||||
clipboard = {
|
||||
enable = true;
|
||||
registers = "unnamedplus";
|
||||
providers.wl-copy.enable = true;
|
||||
};
|
||||
|
||||
options = {
|
||||
encoding = "utf-8";
|
||||
backspace = "indent,eol,start";
|
||||
history = 1000;
|
||||
mouse = "a";
|
||||
updatetime = 300;
|
||||
|
||||
ruler = true;
|
||||
cursorline = true;
|
||||
showcmd = true;
|
||||
showmode = true;
|
||||
laststatus = 1;
|
||||
wildmenu = true;
|
||||
wildmode = ["longest" "list" "full"];
|
||||
ttyfast = true;
|
||||
lazyredraw = true;
|
||||
signcolumn = "no";
|
||||
|
||||
autoindent = true;
|
||||
expandtab = true;
|
||||
smarttab = true;
|
||||
tabstop = 4;
|
||||
shiftwidth = 4;
|
||||
softtabstop = 4;
|
||||
|
||||
hlsearch = true;
|
||||
incsearch = true;
|
||||
|
||||
termguicolors = true;
|
||||
background = "dark";
|
||||
showmatch = true;
|
||||
};
|
||||
|
||||
theme = {
|
||||
enable = true;
|
||||
name = "gruvbox";
|
||||
style = "dark";
|
||||
};
|
||||
|
||||
globals.terminal_ansi_colors = [
|
||||
"#282828"
|
||||
"#cc241d"
|
||||
"#98971a"
|
||||
"#d79921"
|
||||
"#458588"
|
||||
"#b16286"
|
||||
"#689d6a"
|
||||
"#a89984"
|
||||
"#928374"
|
||||
"#fb4934"
|
||||
"#b8bb26"
|
||||
"#fabd2f"
|
||||
"#83a598"
|
||||
"#d3869b"
|
||||
"#8ec07c"
|
||||
"#ebdbb2"
|
||||
];
|
||||
|
||||
keymaps = [
|
||||
{
|
||||
mode = "i";
|
||||
key = "<C-l>";
|
||||
action = "λ";
|
||||
desc = "inserts lambda";
|
||||
}
|
||||
];
|
||||
|
||||
languages.nix = {
|
||||
enable = true;
|
||||
treesitter.enable = true;
|
||||
lsp.enable = true;
|
||||
format.enable = false;
|
||||
extraDiagnostics.enable = false;
|
||||
};
|
||||
|
||||
utility.undotree.enable = true;
|
||||
|
||||
augroups = [
|
||||
{
|
||||
name = "my_filetype_settings";
|
||||
clear = true;
|
||||
}
|
||||
];
|
||||
|
||||
autocmds = [
|
||||
{
|
||||
event = ["FileType"];
|
||||
pattern = [
|
||||
"javascript"
|
||||
"javascriptreact"
|
||||
"typescript"
|
||||
"typescriptreact"
|
||||
"html"
|
||||
"css"
|
||||
"scss"
|
||||
"json"
|
||||
"jsonc"
|
||||
"vue"
|
||||
"svelte"
|
||||
"yaml"
|
||||
"toml"
|
||||
"markdown"
|
||||
"nix"
|
||||
"vim"
|
||||
"ruby"
|
||||
"eruby"
|
||||
"dart"
|
||||
"haskell"
|
||||
"elm"
|
||||
];
|
||||
group = "my_filetype_settings";
|
||||
desc = "2-space indent";
|
||||
command = "setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2";
|
||||
}
|
||||
{
|
||||
event = ["FileType"];
|
||||
pattern = [
|
||||
"python"
|
||||
"rust"
|
||||
"java"
|
||||
"lua"
|
||||
"c"
|
||||
"cpp"
|
||||
"cs"
|
||||
"php"
|
||||
"kotlin"
|
||||
"swift"
|
||||
"scala"
|
||||
"perl"
|
||||
];
|
||||
group = "my_filetype_settings";
|
||||
desc = "4-space indent";
|
||||
command = "setlocal expandtab tabstop=4 shiftwidth=4 softtabstop=4";
|
||||
}
|
||||
{
|
||||
event = ["FileType"];
|
||||
pattern = ["go" "gomod" "make"];
|
||||
group = "my_filetype_settings";
|
||||
desc = "hard tabs";
|
||||
command = "setlocal noexpandtab tabstop=4 shiftwidth=4 softtabstop=0";
|
||||
}
|
||||
{
|
||||
event = ["FileType"];
|
||||
pattern = ["lisp" "scheme" "clojure" "racket" "fennel"];
|
||||
group = "my_filetype_settings";
|
||||
desc = "Lisp-style indent";
|
||||
command = "setlocal expandtab tabstop=2 shiftwidth=2 softtabstop=2 lisp autoindent";
|
||||
}
|
||||
];
|
||||
|
||||
luaConfigRC.my_lispwords = ''
|
||||
vim.opt.lispwords:append({
|
||||
"defun", "defmacro", "defvar", "defparameter", "defmethod",
|
||||
"define-syntax", "lambda", "let", "let*", "letrec", "flet",
|
||||
"labels", "progn", "when", "unless", "if", "cond",
|
||||
})
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
15
modules/users/coyote/programs/obs.nix
Normal file
15
modules/users/coyote/programs/obs.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {pkgs, ...}: {
|
||||
programs.obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
input-overlay
|
||||
droidcam-obs
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
flake.modules.nixos.coyote = {
|
||||
programs.obs-studio.enableVirtualCamera = true;
|
||||
};
|
||||
}
|
||||
15
modules/users/coyote/programs/shell.nix
Normal file
15
modules/users/coyote/programs/shell.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {
|
||||
programs.fish = {
|
||||
enable = true;
|
||||
shellAbbrs = {
|
||||
l = "eza --grid --all";
|
||||
ll = "eza --long --all";
|
||||
ls = "eza";
|
||||
".." = "cd ..";
|
||||
"..." = "cd ../..";
|
||||
cat = "bat";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
20
modules/users/coyote/programs/ssh.nix
Normal file
20
modules/users/coyote/programs/ssh.nix
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {
|
||||
programs.ssh = {
|
||||
enable = true;
|
||||
enableDefaultConfig = false;
|
||||
settings."*" = {
|
||||
ForwardAgent = false;
|
||||
AddKeysToAgent = "yes"; # no passphrase, silent auto-add
|
||||
Compression = false;
|
||||
ServerAliveInterval = 0;
|
||||
ServerAliveCountMax = 3;
|
||||
HashKnownHosts = false;
|
||||
UserKnownHostsFile = "~/.ssh/known_hosts";
|
||||
ControlMaster = "no";
|
||||
ControlPath = "~/.ssh/master-%r@%n:%p";
|
||||
ControlPersist = "no";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
19
modules/users/coyote/programs/starship.nix
Normal file
19
modules/users/coyote/programs/starship.nix
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {pkgs, ...}: {
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.starship;
|
||||
enableTransience = true;
|
||||
settings = {
|
||||
"$schema" = "https://starship.rs/config-schema.json";
|
||||
git_status = {
|
||||
ahead = ">";
|
||||
behind = "<";
|
||||
diverged = "<>";
|
||||
renamed = "r";
|
||||
deleted = "d";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
21
modules/users/coyote/programs/tmux.nix
Normal file
21
modules/users/coyote/programs/tmux.nix
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
flake.modules.homeManager.tmux = {
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
clock24 = true;
|
||||
baseIndex = 1;
|
||||
keyMode = "vi";
|
||||
terminal = "tmux-256color";
|
||||
escapeTime = 10;
|
||||
extraConfig = ''
|
||||
set -g pane-base-index 1
|
||||
set-window-option -g pane-base-index 1
|
||||
set-option -g renumber-windows on
|
||||
set-option -g status-right "\"#W\""
|
||||
set -ga terminal-overrides ",*:RGB"
|
||||
set -g mouse on
|
||||
set -g set-clipboard on
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
8
modules/users/coyote/programs/yt-dlp.nix
Normal file
8
modules/users/coyote/programs/yt-dlp.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
flake.modules.homeManager.coyote = {pkgs, ...}: {
|
||||
programs.yt-dlp = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.yt-dlp;
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Reference in a new issue