From dc2abe6ff19c9b9357007eca7cfd91c51c2c6399 Mon Sep 17 00:00:00 2001 From: "finn.markwitz" Date: Fri, 7 Feb 2025 22:13:20 +0100 Subject: [PATCH] refactor: Formatting --- flake.nix | 26 +++++++++---- machines/configuration.nix | 28 ++++++------- machines/configuration_old.nix | 41 +++++++++++--------- machines/core/core.nix | 10 ++++- machines/core/default.nix | 2 +- machines/core/modules.nix | 9 ++++- machines/core/network.nix | 9 ++++- machines/core/nix.nix | 10 ++++- machines/core/users.nix | 9 ++++- machines/jupiter/configuration.nix | 23 ++++++----- machines/jupiter/disks.nix | 38 +++++++++++------- machines/jupiter/hardware-configuration.nix | 40 ++++++++++++------- machines/mibook/configuration.nix | 10 +++-- machines/mibook/disks.nix | 17 +++++--- machines/mibook/environments.nix | 2 +- machines/mibook/hardware-configuration.nix | 28 ++++++++----- modules/default.nix | 2 +- modules/environments/apps/default.nix | 31 ++++++++------- modules/environments/default.nix | 2 +- modules/environments/development/default.nix | 13 +++++-- modules/environments/docker/default.nix | 11 +++++- modules/environments/hyprland/default.nix | 27 +++++++------ modules/environments/jellyfin/default.nix | 10 +++-- modules/environments/jellyseerr/default.nix | 3 +- modules/environments/kde-desktop/default.nix | 15 ++++--- modules/environments/paperless/default.nix | 24 ++++++------ modules/environments/prowlarr/default.nix | 13 +++++-- modules/environments/radarr/default.nix | 13 +++++-- modules/environments/readarr/default.nix | 13 +++++-- modules/environments/sonarr/default.nix | 11 ++++-- modules/environments/zsh/default.nix | 23 ++++++----- modules/hardware/bluetooth/default.nix | 7 +++- modules/hardware/default.nix | 2 +- modules/hardware/sound/default.nix | 11 ++++-- modules/hardware/wifi/default.nix | 9 ++++- pkgs/default.nix | 5 +-- 36 files changed, 349 insertions(+), 198 deletions(-) diff --git a/flake.nix b/flake.nix index bf33ccd..74463d3 100644 --- a/flake.nix +++ b/flake.nix @@ -1,7 +1,6 @@ { description = "NixOS configuration"; - inputs = { nix.url = "github:NixOS/nix"; nixpkgs.url = "nixpkgs/nixos-24.11"; @@ -14,22 +13,33 @@ }; # hyprland.url = "github:hyprwm/Hyprland"; - }; + }; - outputs = inputs@{ self, flake-parts, ... }: + outputs = + inputs@{ self, flake-parts, ... }: flake-parts.lib.mkFlake { inherit inputs; } { imports = [ ./machines/configuration.nix ]; - perSystem = { self', inputs', config, pkgs, system, ... }: { - # make pkgs available to all `perSystem` functions - _module.args.pkgs = import inputs.nixpkgs { - inherit system; + perSystem = + { + self', + inputs', + config, + pkgs, + system, + ... + }: + { + # make pkgs available to all `perSystem` functions + _module.args.pkgs = import inputs.nixpkgs { + inherit system; + }; }; - }; systems = [ "x86_64-linux" ]; }; + formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-rfc-style; } diff --git a/machines/configuration.nix b/machines/configuration.nix index 67e18f2..ac64523 100644 --- a/machines/configuration.nix +++ b/machines/configuration.nix @@ -1,7 +1,6 @@ { self, ... }: let - inherit - (self.inputs) + inherit (self.inputs) nixpkgs nixpkgs-unstable nixos-hardware @@ -24,16 +23,19 @@ let } { imports = [ - ({ pkgs, ... }: { - nixpkgs.overlays = [ - overlay-unstable - (import ../pkgs) - ]; - nix.nixPath = [ - "nixpkgs=${pkgs.path}" - ]; - documentation.info.enable = false; - }) + ( + { pkgs, ... }: + { + nixpkgs.overlays = [ + overlay-unstable + (import ../pkgs) + ]; + nix.nixPath = [ + "nixpkgs=${pkgs.path}" + ]; + documentation.info.enable = false; + } + ) #hyprland.nixosModules.default ]; } @@ -60,4 +62,4 @@ in ]; }; }; -} \ No newline at end of file +} diff --git a/machines/configuration_old.nix b/machines/configuration_old.nix index d0e0dbf..19f29ed 100644 --- a/machines/configuration_old.nix +++ b/machines/configuration_old.nix @@ -5,10 +5,10 @@ { config, pkgs, ... }: { - imports = - [ # Include the results of the hardware scan. - ./hardware-configuration.nix - ]; + imports = [ + # Include the results of the hardware scan. + ./hardware-configuration.nix + ]; # Bootloader. boot.loader.grub.enable = true; @@ -85,22 +85,25 @@ users.users.finn = { isNormalUser = true; description = "Finn Markwitz"; - extraGroups = [ "networkmanager" "wheel" ]; + extraGroups = [ + "networkmanager" + "wheel" + ]; packages = with pkgs; [ - firefox - jetbrains.webstorm - jetbrains.goland - jetbrains.pycharm-professional - jetbrains.idea-ultimate - thunderbird - google-chrome - discord - spotify - keepassxc - nextcloud-client - zsh - oh-my-zsh - neovim + firefox + jetbrains.webstorm + jetbrains.goland + jetbrains.pycharm-professional + jetbrains.idea-ultimate + thunderbird + google-chrome + discord + spotify + keepassxc + nextcloud-client + zsh + oh-my-zsh + neovim ]; }; diff --git a/machines/core/core.nix b/machines/core/core.nix index 1a69871..8c830a4 100644 --- a/machines/core/core.nix +++ b/machines/core/core.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { # Packages environment.systemPackages = with pkgs; [ @@ -40,6 +45,7 @@ networkmanager lm_sensors systemctl-tui + nixfmt-rfc-style ]; time.timeZone = "Europe/Berlin"; @@ -63,4 +69,4 @@ LC_TIME = "de_DE.UTF-8"; }; -} \ No newline at end of file +} diff --git a/machines/core/default.nix b/machines/core/default.nix index 882e680..8f95b17 100644 --- a/machines/core/default.nix +++ b/machines/core/default.nix @@ -4,4 +4,4 @@ ./network.nix ./nix.nix ./users.nix -] \ No newline at end of file +] diff --git a/machines/core/modules.nix b/machines/core/modules.nix index 9760f1b..6d56072 100644 --- a/machines/core/modules.nix +++ b/machines/core/modules.nix @@ -1,3 +1,8 @@ # Generate via nix-generate -{ config, lib, pkgs, ... }: -{} \ No newline at end of file +{ + config, + lib, + pkgs, + ... +}: +{ } diff --git a/machines/core/network.nix b/machines/core/network.nix index 4277a34..a5410e5 100644 --- a/machines/core/network.nix +++ b/machines/core/network.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: { networking.networkmanager = { @@ -12,4 +17,4 @@ ]; }; -} \ No newline at end of file +} diff --git a/machines/core/nix.nix b/machines/core/nix.nix index 3e4359a..6a23115 100644 --- a/machines/core/nix.nix +++ b/machines/core/nix.nix @@ -1,4 +1,10 @@ -{ config, lib, pkgs, inputs, ... }: +{ + config, + lib, + pkgs, + inputs, + ... +}: { nix = { daemonCPUSchedPolicy = "idle"; @@ -24,4 +30,4 @@ }; }; nixpkgs.config.allowUnfree = true; -} \ No newline at end of file +} diff --git a/machines/core/users.nix b/machines/core/users.nix index 644f11f..8e5e906 100644 --- a/machines/core/users.nix +++ b/machines/core/users.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { users.users.finn = { @@ -24,4 +29,4 @@ users.groups.finn = { gid = 1000; }; -} \ No newline at end of file +} diff --git a/machines/jupiter/configuration.nix b/machines/jupiter/configuration.nix index a2c7520..9ae63de 100644 --- a/machines/jupiter/configuration.nix +++ b/machines/jupiter/configuration.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { imports = [ @@ -8,20 +13,20 @@ ]; networking.hostName = "jupiter"; - + boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; boot.kernelPackages = pkgs.unstable.linuxPackages_latest; # Shitfuck SOnar Dotnet dependency nixpkgs.config = { - permittedInsecurePackages = [ - "aspnetcore-runtime-6.0.36" - "aspnetcore-runtime-wrapped-6.0.36" - "dotnet-sdk-6.0.428" - "dotnet-sdk-wrapped-6.0.428" - ]; - }; + permittedInsecurePackages = [ + "aspnetcore-runtime-6.0.36" + "aspnetcore-runtime-wrapped-6.0.36" + "dotnet-sdk-6.0.428" + "dotnet-sdk-wrapped-6.0.428" + ]; + }; services.openssh.enable = true; diff --git a/machines/jupiter/disks.nix b/machines/jupiter/disks.nix index 3a28256..4a9499d 100644 --- a/machines/jupiter/disks.nix +++ b/machines/jupiter/disks.nix @@ -1,22 +1,30 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: -#TODO: CHECK THIS OUT: https://github.com/nix-community/disko its kinda better but felix does not support it +#TODO: CHECK THIS OUT: https://github.com/nix-community/disko its kinda better but felix does not support it { - fileSystems."/" = - { device = "/dev/disk/by-uuid/c95c64ad-f131-4bde-9bca-a7a3692173da"; - fsType = "ext4"; - }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/c95c64ad-f131-4bde-9bca-a7a3692173da"; + fsType = "ext4"; + }; - fileSystems."/boot" = - { device = "/dev/disk/by-uuid/0D77-17BB"; - fsType = "vfat"; - }; + fileSystems."/boot" = { + device = "/dev/disk/by-uuid/0D77-17BB"; + fsType = "vfat"; + }; - fileSystems."/data/nfs" = - { device = "voyager:/"; - fsType = "nfs"; - options = [ "x-systemd.automount" "noauto" ]; - }; + fileSystems."/data/nfs" = { + device = "voyager:/"; + fsType = "nfs"; + options = [ + "x-systemd.automount" + "noauto" + ]; + }; } diff --git a/machines/jupiter/hardware-configuration.nix b/machines/jupiter/hardware-configuration.nix index 3d095bf..13cbe80 100644 --- a/machines/jupiter/hardware-configuration.nix +++ b/machines/jupiter/hardware-configuration.nix @@ -1,14 +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") - ]; + imports = [ + (modulesPath + "/installer/scan/not-detected.nix") + ]; - boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" ]; + boot.initrd.availableKernelModules = [ + "xhci_pci" + "ahci" + "nvme" + "usbhid" + ]; boot.initrd.kernelModules = [ ]; boot.kernelModules = [ "kvm-intel" ]; boot.extraModulePackages = [ ]; @@ -16,7 +27,7 @@ # 9a49 nixpkgs.config.packageOverrides = pkgs: { - vaapiIntel = pkgs.vaapiIntel.override { enableHybridCodec = true; }; + vaapiIntel = pkgs.vaapiIntel.override { enableHybridCodec = true; }; }; hardware.opengl = { enable = true; @@ -33,16 +44,15 @@ enableGraphical = true; }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/c95c64ad-f131-4bde-9bca-a7a3692173da"; + fsType = "ext4"; + }; - fileSystems."/" = - { device = "/dev/disk/by-uuid/c95c64ad-f131-4bde-9bca-a7a3692173da"; - fsType = "ext4"; - }; - - fileSystems."/boot" = - { device = "/dev/disk/by-uuid/0D77-17BB"; - fsType = "vfat"; - }; + fileSystems."/boot" = { + device = "/dev/disk/by-uuid/0D77-17BB"; + fsType = "vfat"; + }; swapDevices = [ ]; diff --git a/machines/mibook/configuration.nix b/machines/mibook/configuration.nix index afc02aa..b7d1bfa 100644 --- a/machines/mibook/configuration.nix +++ b/machines/mibook/configuration.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: { imports = [ @@ -50,9 +55,8 @@ #media-session.enable = true; }; - system = { stateVersion = "23.05"; autoUpgrade.enable = true; }; -} \ No newline at end of file +} diff --git a/machines/mibook/disks.nix b/machines/mibook/disks.nix index 31f92bd..6ac41c9 100644 --- a/machines/mibook/disks.nix +++ b/machines/mibook/disks.nix @@ -1,10 +1,15 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: -#TODO: CHECK THIS OUT: https://github.com/nix-community/disko its kinda better but felix does not support it +#TODO: CHECK THIS OUT: https://github.com/nix-community/disko its kinda better but felix does not support it { - fileSystems."/" = - { device = "/dev/disk/by-uuid/077abdb0-cbc1-4589-b411-25ecc157488f"; - fsType = "ext4"; - }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/077abdb0-cbc1-4589-b411-25ecc157488f"; + fsType = "ext4"; + }; } diff --git a/machines/mibook/environments.nix b/machines/mibook/environments.nix index 9655e58..d1a2d8e 100644 --- a/machines/mibook/environments.nix +++ b/machines/mibook/environments.nix @@ -12,4 +12,4 @@ in dev_apps = true; }; }; -} \ No newline at end of file +} diff --git a/machines/mibook/hardware-configuration.nix b/machines/mibook/hardware-configuration.nix index 5d56eb6..e4303e0 100644 --- a/machines/mibook/hardware-configuration.nix +++ b/machines/mibook/hardware-configuration.nix @@ -1,22 +1,32 @@ # 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" "ahci" "nvme" ]; + boot.initrd.availableKernelModules = [ + "xhci_pci" + "ahci" + "nvme" + ]; boot.initrd.kernelModules = [ ]; boot.kernelModules = [ "kvm-intel" ]; boot.extraModulePackages = [ ]; - fileSystems."/" = - { device = "/dev/disk/by-uuid/077abdb0-cbc1-4589-b411-25ecc157488f"; - fsType = "ext4"; - }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/077abdb0-cbc1-4589-b411-25ecc157488f"; + fsType = "ext4"; + }; swapDevices = [ ]; diff --git a/modules/default.nix b/modules/default.nix index e6144e5..2c50bf8 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -4,4 +4,4 @@ ./environments ./hardware ]; -} \ No newline at end of file +} diff --git a/modules/environments/apps/default.nix b/modules/environments/apps/default.nix index f577fa7..0bd4255 100644 --- a/modules/environments/apps/default.nix +++ b/modules/environments/apps/default.nix @@ -1,10 +1,13 @@ - -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.apps; - in { - - +in +{ options.my.profiles.apps = with lib; { desktop_apps = mkEnableOption "Basic Apps"; @@ -16,17 +19,17 @@ let users.users.finn.packages = with pkgs; [ firefox thunderbird - google-chrome + google-chrome vscode - discord - spotify - keepassxc + discord + spotify + keepassxc moonlight-qt - nextcloud-client - pipewire + nextcloud-client + pipewire wireplumber - vlc + vlc ghostty ]; - }; - } + }; +} diff --git a/modules/environments/default.nix b/modules/environments/default.nix index 038af51..cc5cab2 100644 --- a/modules/environments/default.nix +++ b/modules/environments/default.nix @@ -15,4 +15,4 @@ ./jellyfin ./jellyseerr ]; -} \ No newline at end of file +} diff --git a/modules/environments/development/default.nix b/modules/environments/development/default.nix index ca9fcea..615f936 100644 --- a/modules/environments/development/default.nix +++ b/modules/environments/development/default.nix @@ -1,6 +1,13 @@ -{ config, lib, pkgs, ... }: -let cfg = config.my.profiles.development; -in { +{ + config, + lib, + pkgs, + ... +}: +let + cfg = config.my.profiles.development; +in +{ options.my.profiles.development = with lib; { enable = mkEnableOption "Development Tools"; diff --git a/modules/environments/docker/default.nix b/modules/environments/docker/default.nix index b3cd871..4917f17 100644 --- a/modules/environments/docker/default.nix +++ b/modules/environments/docker/default.nix @@ -1,5 +1,12 @@ # Docker related settings -{ config, inputs, lib, options, pkgs, ... }: +{ + config, + inputs, + lib, + options, + pkgs, + ... +}: let cfg = config.my.profiles.docker; in @@ -19,4 +26,4 @@ in autoPrune.enable = true; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/hyprland/default.nix b/modules/environments/hyprland/default.nix index 32594ff..c8aa0c5 100644 --- a/modules/environments/hyprland/default.nix +++ b/modules/environments/hyprland/default.nix @@ -1,7 +1,13 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.hyprland; - in { +in +{ options.my.profiles.hyprland = with lib; { enable = mkEnableOption "hyprland env"; }; @@ -12,12 +18,11 @@ let xwayland.enable = true; }; - services.displayManager.sddm.wayland.enable = true; services.xserver = { - layout = "de"; - xkbVariant = ""; - }; + layout = "de"; + xkbVariant = ""; + }; users.users.finn.packages = with pkgs; [ wofi mako @@ -30,12 +35,12 @@ let #xdg-desktop-portal-hyprland ]; hardware = { - # Opengl - opengl.enable = true; + # Opengl + opengl.enable = true; - # Most wayland compositors need this - nvidia.modesetting.enable = true; - }; + # Most wayland compositors need this + nvidia.modesetting.enable = true; + }; }; } diff --git a/modules/environments/jellyfin/default.nix b/modules/environments/jellyfin/default.nix index 7a63ae8..88e165c 100644 --- a/modules/environments/jellyfin/default.nix +++ b/modules/environments/jellyfin/default.nix @@ -1,5 +1,10 @@ # manages and downloads films -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.jellyfin; in @@ -15,9 +20,8 @@ in openFirewall = true; }; - systemd.services.jellyfin = { after = [ "network-online.target" ]; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/jellyseerr/default.nix b/modules/environments/jellyseerr/default.nix index 659874e..11bbbb3 100644 --- a/modules/environments/jellyseerr/default.nix +++ b/modules/environments/jellyseerr/default.nix @@ -1,4 +1,3 @@ - # manages and downloads films { config, lib, ... }: let @@ -20,4 +19,4 @@ in after = [ "network-online.target" ]; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/kde-desktop/default.nix b/modules/environments/kde-desktop/default.nix index 3a554db..0a7cbc6 100644 --- a/modules/environments/kde-desktop/default.nix +++ b/modules/environments/kde-desktop/default.nix @@ -1,5 +1,10 @@ # KDE Desktio Environment -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.kde-desktop; in @@ -10,13 +15,13 @@ in config = lib.mkIf cfg.enable { services.xserver = { - enable = true; - displayManager.sddm.enable = true; - desktopManager.plasma5.enable = true; + enable = true; + displayManager.sddm.enable = true; + desktopManager.plasma5.enable = true; }; users.users.finn.packages = with pkgs; [ # Programms can be added here... numix-icon-theme ]; }; -} \ No newline at end of file +} diff --git a/modules/environments/paperless/default.nix b/modules/environments/paperless/default.nix index 2865247..967c485 100644 --- a/modules/environments/paperless/default.nix +++ b/modules/environments/paperless/default.nix @@ -8,18 +8,20 @@ in enable = mkEnableOption "Paperless Server"; port = mkOption { - type = types.port; - default = 28981; - example = 8080; - description = "Internal port for webui"; - }; + type = types.port; + default = 28981; + example = 8080; + description = "Internal port for webui"; + }; extraConfig = mkOption { - type = types.attrs; - default = {}; - example = { PAPERLESS_OCR_LANGUAGE = "deu+eng"; }; - description = "Extra configuration options"; - }; + type = types.attrs; + default = { }; + example = { + PAPERLESS_OCR_LANGUAGE = "deu+eng"; + }; + description = "Extra configuration options"; + }; }; config = lib.mkIf cfg.enable { @@ -33,4 +35,4 @@ in }; networking.firewall.allowedTCPPorts = [ cfg.port ]; }; -} \ No newline at end of file +} diff --git a/modules/environments/prowlarr/default.nix b/modules/environments/prowlarr/default.nix index d53b78c..9584d3f 100644 --- a/modules/environments/prowlarr/default.nix +++ b/modules/environments/prowlarr/default.nix @@ -1,10 +1,15 @@ # manages indexes -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.prowlarr; - # domain = config.networking.domain; - # port = 9696; in +# domain = config.networking.domain; +# port = 9696; { options.my.profiles.prowlarr = with lib; { enable = mkEnableOption "Prowlarr for indexing"; @@ -30,4 +35,4 @@ in after = [ "network-online.target" ]; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/radarr/default.nix b/modules/environments/radarr/default.nix index 7a4f96a..a2c1d6f 100644 --- a/modules/environments/radarr/default.nix +++ b/modules/environments/radarr/default.nix @@ -1,10 +1,15 @@ # manages and downloads films -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.radarr; - # domain = config.networking.domain; - # port = 7878; in +# domain = config.networking.domain; +# port = 7878; { options.my.profiles.radarr = with lib; { enable = mkEnableOption "Sonarr for films management"; @@ -23,4 +28,4 @@ in after = [ "network-online.target" ]; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/readarr/default.nix b/modules/environments/readarr/default.nix index 82ca277..e95a623 100644 --- a/modules/environments/readarr/default.nix +++ b/modules/environments/readarr/default.nix @@ -1,10 +1,15 @@ # manages and downloads films -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.readarr; - # domain = config.networking.domain; - # port = 7878; in +# domain = config.networking.domain; +# port = 7878; { options.my.profiles.readarr = with lib; { enable = mkEnableOption "Readarr for ebook management"; @@ -23,4 +28,4 @@ in after = [ "network-online.target" ]; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/sonarr/default.nix b/modules/environments/sonarr/default.nix index 8f1dd9c..084a286 100644 --- a/modules/environments/sonarr/default.nix +++ b/modules/environments/sonarr/default.nix @@ -1,9 +1,14 @@ # manages and downloads films -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.sonarr; # domain = config.networking.domain; - port = 8989; + port = 8989; in { options.my.profiles.sonarr = with lib; { @@ -23,4 +28,4 @@ in after = [ "network-online.target" ]; }; }; -} \ No newline at end of file +} diff --git a/modules/environments/zsh/default.nix b/modules/environments/zsh/default.nix index b469db7..09ceeb7 100644 --- a/modules/environments/zsh/default.nix +++ b/modules/environments/zsh/default.nix @@ -1,9 +1,13 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.profiles.zsh; - in { - - +in +{ options.my.profiles.zsh = with lib; { enable = mkEnableOption "zsh env"; @@ -12,13 +16,12 @@ let config = lib.mkIf cfg.enable { users.defaultUserShell = pkgs.zsh; programs.zsh = { + enable = true; + ohMyZsh = { enable = true; - ohMyZsh = { - enable = true; - theme = "agnoster"; - }; + theme = "agnoster"; + }; }; - }; - + }; } diff --git a/modules/hardware/bluetooth/default.nix b/modules/hardware/bluetooth/default.nix index dab77e7..d00c942 100644 --- a/modules/hardware/bluetooth/default.nix +++ b/modules/hardware/bluetooth/default.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.hardware.bluetooth; in diff --git a/modules/hardware/default.nix b/modules/hardware/default.nix index 71e9c03..59038c3 100644 --- a/modules/hardware/default.nix +++ b/modules/hardware/default.nix @@ -14,4 +14,4 @@ #./thunderbolt #./wifi ]; -} \ No newline at end of file +} diff --git a/modules/hardware/sound/default.nix b/modules/hardware/sound/default.nix index 8e802d5..4c4a7f2 100644 --- a/modules/hardware/sound/default.nix +++ b/modules/hardware/sound/default.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.hardware.bluetooth; in @@ -7,8 +12,6 @@ in enable = mkEnableOption "Sound configuration"; }; - - config = lib.mkIf cfg.enable { hardware.pulseaudio.enable = false; hardware.pulseaudio.support32Bit = true; @@ -17,4 +20,4 @@ in headsetcontrol ]; }; -} \ No newline at end of file +} diff --git a/modules/hardware/wifi/default.nix b/modules/hardware/wifi/default.nix index d430c8d..8b0f648 100644 --- a/modules/hardware/wifi/default.nix +++ b/modules/hardware/wifi/default.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let cfg = config.my.hardware.wifi; in @@ -13,4 +18,4 @@ in package = pkgs.rtw89-firmware; }; }; -} \ No newline at end of file +} diff --git a/pkgs/default.nix b/pkgs/default.nix index 7a11111..bebb2e9 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -1,4 +1,3 @@ -final: prev: -{ +final: prev: { # homer = final.callPackage ./homer { }; -} \ No newline at end of file +}