From ad673fbcf74433f4fc89931918730ccde3839da3 Mon Sep 17 00:00:00 2001 From: Tasia Iso Date: Mon, 22 Apr 2024 21:47:52 +0200 Subject: [PATCH] e --- common/base.nix | 2 +- common/components/dm/sddm.nix | 6 +++ common/components/packages-base.nix | 23 +++++++++ .../{packages.nix => packages-full.nix} | 47 ++++++++++------- common/components/printing.nix | 4 ++ common/components/sound.nix | 13 +++++ common/full-install.nix | 51 +++---------------- common/hardware/wireless.nix | 4 +- 8 files changed, 86 insertions(+), 64 deletions(-) create mode 100644 common/components/packages-base.nix rename common/components/{packages.nix => packages-full.nix} (57%) create mode 100644 common/components/printing.nix create mode 100644 common/components/sound.nix diff --git a/common/base.nix b/common/base.nix index 8a94615..f550030 100644 --- a/common/base.nix +++ b/common/base.nix @@ -9,7 +9,7 @@ imports = [ ./components/bootloader.nix ./components/networking.nix - ./components/packages.nix + ./components/packages-base.nix ./components/security.nix ./locales/paris.nix diff --git a/common/components/dm/sddm.nix b/common/components/dm/sddm.nix index f545269..9480317 100644 --- a/common/components/dm/sddm.nix +++ b/common/components/dm/sddm.nix @@ -3,6 +3,12 @@ sddm = { enable = true; wayland.enable = true; + + settings = { + General = { + Numlock = "on"; + }; + }; }; defaultSession = "plasma"; diff --git a/common/components/packages-base.nix b/common/components/packages-base.nix new file mode 100644 index 0000000..4d91a50 --- /dev/null +++ b/common/components/packages-base.nix @@ -0,0 +1,23 @@ +{ + pkgs, + lib, + ... +}: { + # Packages installd on every machine + environment.systemPackages = with pkgs; [ + wget + dig + nmap + btop + gitFull + smartmontools + lm_sensors + pciutils + gcc + gnumake + sysstat + file + ffmpeg + usbutils + ]; +} diff --git a/common/components/packages.nix b/common/components/packages-full.nix similarity index 57% rename from common/components/packages.nix rename to common/components/packages-full.nix index e7160b9..50afaaf 100644 --- a/common/components/packages.nix +++ b/common/components/packages-full.nix @@ -3,6 +3,36 @@ lib, ... }: { + # Packages installed on full-install machines + environment.systemPackages = with pkgs; [ + bat + + nextdns + + # need to test + helix + holehe + smartmontools + cheat + lazygit + ripgrep + jq + yq + neofetch + tldr + dust + powertop + fzf + atuin + zellij + eza + lapce + gotty + gping + yazi + vulnix # once im on stable + ]; + # Unfree packages that can be installes regardless of whether "allow-unfree.nix" is imported nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ @@ -15,21 +45,4 @@ "nvidia-x11" "nvidia-settings" ]; - - environment.systemPackages = with pkgs; [ - wget - dig - nmap - btop - gitFull - smartmontools - lm_sensors - pciutils - gcc - gnumake - sysstat - file - ffmpeg - usbutils - ]; } diff --git a/common/components/printing.nix b/common/components/printing.nix new file mode 100644 index 0000000..771c5d7 --- /dev/null +++ b/common/components/printing.nix @@ -0,0 +1,4 @@ +{ + # Enable CUPS to print documents. + services.printing.enable = true; +} \ No newline at end of file diff --git a/common/components/sound.nix b/common/components/sound.nix new file mode 100644 index 0000000..3bd0919 --- /dev/null +++ b/common/components/sound.nix @@ -0,0 +1,13 @@ +{ + # Enable sound with pipewire. + sound.enable = true; + hardware.pulseaudio.enable = false; + security.rtkit.enable = true; + + services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + }; +} \ No newline at end of file diff --git a/common/full-install.nix b/common/full-install.nix index ff53c06..9c1d10e 100644 --- a/common/full-install.nix +++ b/common/full-install.nix @@ -1,44 +1,7 @@ -{pkgs, ...}: { - # Enable CUPS to print documents. - services.printing.enable = true; - - # Enable sound with pipewire. - sound.enable = true; - hardware.pulseaudio.enable = false; - security.rtkit.enable = true; - services.pipewire = { - enable = true; - alsa.enable = true; - alsa.support32Bit = true; - pulse.enable = true; - }; - - environment.systemPackages = with pkgs; [ - bat - - nextdns - - # need to test - helix - holehe - smartmontools - cheat - lazygit - ripgrep - jq - yq - neofetch - tldr - dust - powertop - fzf - atuin - zellij - eza - lapce - gotty - gping - yazi - vulnix # once im on stable - ]; -} +{ + imports = [ + ./components/sound.nix + ./components/printing.nix + ./components/packages-full.nix + ] +} \ No newline at end of file diff --git a/common/hardware/wireless.nix b/common/hardware/wireless.nix index 8913f86..6e100d3 100644 --- a/common/hardware/wireless.nix +++ b/common/hardware/wireless.nix @@ -2,5 +2,5 @@ imports = [ ./wifi.nix ./bluetooth.nix - ] -} \ No newline at end of file + ]; +}