repo: clean code

This commit is contained in:
Anthony Rodriguez 2024-09-25 09:02:43 +02:00
parent 9af73f65f4
commit 87eff73b58
Signed by: nezia
GPG key ID: EE3BE97C040A86CE
22 changed files with 121 additions and 113 deletions

View file

@ -1,3 +1,3 @@
{...}: { _: {
services.udiskie.enable = true; services.udiskie.enable = true;
} }

View file

@ -1,6 +1,8 @@
{inputs, ...}: { _: {
home.username = "nezia"; home = {
home.homeDirectory = "/home/nezia"; username = "nezia";
homeDirectory = "/home/nezia";
stateVersion = "24.05";
};
programs.home-manager.enable = true; programs.home-manager.enable = true;
home.stateVersion = "24.05";
} }

View file

@ -1,4 +1,4 @@
{...}: { _: {
xdg.mimeApps = { xdg.mimeApps = {
enable = true; enable = true;
defaultApplications = { defaultApplications = {

View file

@ -1,4 +1,4 @@
{...}: { _: {
programs.git = { programs.git = {
enable = true; enable = true;
userName = "Anthony Rodriguez"; userName = "Anthony Rodriguez";

View file

@ -1,4 +1,4 @@
{...}: { _: {
programs.gpg = { programs.gpg = {
enable = true; enable = true;
publicKeys = [ publicKeys = [

View file

@ -1,4 +1,4 @@
{...}: { _: {
programs = { programs = {
direnv = { direnv = {
enable = true; enable = true;

View file

@ -20,7 +20,7 @@ in {
plugins = [ plugins = [
{ {
name = "fzf"; name = "fzf";
src = pkgs.fishPlugins.fzf.src; inherit (pkgs.fishPlugins.fzf) src;
} }
]; ];
}; };

View file

@ -1,4 +1,4 @@
{...}: { _: {
programs.starship = { programs.starship = {
enable = true; enable = true;
enableTransience = true; enableTransience = true;

View file

@ -1,4 +1,4 @@
{...}: { _: {
programs.zellij = { programs.zellij = {
enable = true; enable = true;
settings = { settings = {

View file

@ -1,4 +1,4 @@
{...}: { _: {
programs.zoxide = { programs.zoxide = {
enable = true; enable = true;
enableBashIntegration = false; enableBashIntegration = false;

View file

@ -4,9 +4,10 @@ _: {
./syncthing ./syncthing
./sops.nix ./sops.nix
]; ];
modules = {
modules.gnome.enable = true; gnome.enable = true;
modules.stylix.enable = true; stylix.enable = true;
modules.docker.enable = true; docker.enable = true;
modules.pipewire.enable = true; pipewire.enable = true;
};
} }

View file

@ -3,10 +3,12 @@
username, username,
... ...
}: { }: {
sops.defaultSopsFile = ../../secrets/secrets.yaml; sops = {
sops.defaultSopsFormat = "yaml"; defaultSopsFile = ../../secrets/secrets.yaml;
sops.age.keyFile = "/home/${username}/.config/sops/age/keys.txt"; defaultSopsFormat = "yaml";
age.keyFile = "/home/${username}/.config/sops/age/keys.txt";
sops.secrets."syncthing/${hostname}/key" = {}; secrets."syncthing/${hostname}/key" = {};
sops.secrets."syncthing/${hostname}/cert" = {}; secrets."syncthing/${hostname}/cert" = {};
};
} }

View file

@ -1,4 +1,4 @@
{...}: { _: {
boot = { boot = {
loader = { loader = {
timeout = 0; timeout = 0;

View file

@ -1,12 +1,18 @@
{hostname, ...}: { {hostname, ...}: {
networking.hostName = hostname; networking.hostName = hostname;
networking.networkmanager.enable = true; networking.networkmanager.enable = true;
services = {
services.xserver.xkb = { xserver.xkb = {
layout = "us"; layout = "us";
variant = ""; variant = "";
}; };
# automount
udisks2.enable = true;
fwupd.enable = true;
};
users.users.nezia = { users.users.nezia = {
isNormalUser = true; isNormalUser = true;
description = "Anthony Rodriguez"; description = "Anthony Rodriguez";
@ -16,11 +22,6 @@
]; ];
}; };
# automount
services.udisks2.enable = true;
services.fwupd.enable = true;
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
hardware.enableAllFirmware = true; hardware.enableAllFirmware = true;

View file

@ -1,4 +1,4 @@
{...}: { _: {
# Set your time zone. # Set your time zone.
time.timeZone = "Europe/Paris"; time.timeZone = "Europe/Paris";

View file

@ -1,4 +1,4 @@
{...}: { _: {
# fix direnv integration with fish # fix direnv integration with fish
environment.pathsToLink = ["/share/fish"]; environment.pathsToLink = ["/share/fish"];

View file

@ -1,17 +1,23 @@
{pkgs, ...}: { {pkgs, ...}: {
services = {
# setup printing service # setup printing service
services.printing.enable = true; printing.enable = true;
services.avahi = { avahi = {
enable = true; enable = true;
nssmdns4 = true; nssmdns4 = true;
openFirewall = true; openFirewall = true;
}; };
services.printing.drivers = [ printing.drivers = [
pkgs.gutenprint pkgs.gutenprint
pkgs.hplip pkgs.hplip
]; ];
udev.packages = [
pkgs.sane-airscan
pkgs.utsushi
];
};
hardware.sane.enable = true; # enables support for SANE scanners hardware.sane.enable = true; # enables support for SANE scanners
hardware.sane.extraBackends = [ hardware.sane.extraBackends = [
@ -20,8 +26,4 @@
pkgs.epkowa # Epson pkgs.epkowa # Epson
pkgs.utsushi # other printers pkgs.utsushi # other printers
]; ];
services.udev.packages = [
pkgs.sane-airscan
pkgs.utsushi
];
} }

View file

@ -4,15 +4,14 @@
{ {
config, config,
lib, lib,
pkgs,
modulesPath, modulesPath,
... ...
}: { }: {
imports = [ imports = [
(modulesPath + "/installer/scan/not-detected.nix") (modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot = {
boot.initrd.availableKernelModules = [ initrd.availableKernelModules = [
"nvme" "nvme"
"xhci_pci" "xhci_pci"
"ahci" "ahci"
@ -20,9 +19,10 @@
"usbhid" "usbhid"
"sd_mod" "sd_mod"
]; ];
boot.initrd.kernelModules = []; initrd.kernelModules = [];
boot.kernelModules = ["kvm-amd"]; kernelModules = ["kvm-amd"];
boot.extraModulePackages = []; extraModulePackages = [];
};
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-label/NIXROOT"; device = "/dev/disk/by-label/NIXROOT";

View file

@ -3,10 +3,10 @@
./hardware-configuration.nix ./hardware-configuration.nix
inputs.nixos-hardware.nixosModules.framework-13-7040-amd inputs.nixos-hardware.nixosModules.framework-13-7040-amd
]; ];
services = {
services.fprintd.enable = true; fprintd.enable = true;
services.power-profiles-daemon.enable = true; power-profiles-daemon.enable = true;
services.keyd = { keyd = {
enable = true; enable = true;
keyboards = { keyboards = {
default = { default = {
@ -19,6 +19,7 @@
}; };
}; };
}; };
};
modules = { modules = {
neovim.enable = true; neovim.enable = true;
wezterm.enable = true; wezterm.enable = true;

View file

@ -4,31 +4,33 @@
{ {
config, config,
lib, lib,
pkgs,
modulesPath, modulesPath,
... ...
}: { }: {
imports = [ imports = [
(modulesPath + "/installer/scan/not-detected.nix") (modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot = {
boot.initrd.availableKernelModules = [ initrd = {
availableKernelModules = [
"nvme" "nvme"
"xhci_pci" "xhci_pci"
"thunderbolt" "thunderbolt"
"usb_storage" "usb_storage"
"sd_mod" "sd_mod"
]; ];
boot.initrd.kernelModules = [ kernelModules = [
"amdgpu" "amdgpu"
"dm-snapshot" "dm-snapshot"
]; ];
boot.kernelModules = [ luks.devices."crypt".device = "/dev/disk/by-uuid/39d0e0c6-ea32-4ee4-ac76-b28fbff687f8";
};
kernelModules = [
"kvm-amd" "kvm-amd"
"cryptd" "cryptd"
]; ];
boot.initrd.luks.devices."crypt".device = "/dev/disk/by-uuid/39d0e0c6-ea32-4ee4-ac76-b28fbff687f8"; extraModulePackages = [];
boot.extraModulePackages = []; };
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-uuid/4ef04567-9633-45b9-addc-55c3020f45b7"; device = "/dev/disk/by-uuid/4ef04567-9633-45b9-addc-55c3020f45b7";

View file

@ -27,8 +27,7 @@ in {
}; };
}; };
environment.gnome.excludePackages = ( environment.gnome.excludePackages = with pkgs; [
with pkgs; [
gnome-console gnome-console
gnome-photos gnome-photos
gnome-tour gnome-tour
@ -45,8 +44,7 @@ in {
epiphany epiphany
geary geary
yelp yelp
] ];
);
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
gnome-tweaks gnome-tweaks

View file

@ -1,7 +1,6 @@
{ {
config, config,
lib, lib,
inputs,
username, username,
... ...
}: let }: let