Restructured the packages into modules

This commit is contained in:
Asdam9
2026-08-05 08:07:43 +02:00
parent 78b9584009
commit ce39f446ac
3 changed files with 17 additions and 12 deletions

View File

@@ -2,7 +2,8 @@
flake.nixosModules.laptopConfiguration = { config, pkgs, self', ... }: {
imports =
[ # Include the results of the hardware scan.
self.nixosModules.base
self.nixosModules.user
self.nixosModules.main
self.nixosModules.laptopHardware
self.nixosModules.visualProfile
self.nixosModules.developmentProfile
@@ -26,7 +27,7 @@
boot.kernelPackages = pkgs.linuxPackages_latest;
networking.hostName = "laptop"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
powerManagement.enable = true;
services.power-profiles-daemon.enable = true;
@@ -82,15 +83,7 @@
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
wget
zathura
zip
unzip
faugus-launcher
mpv
nix-sweep
#self.packages.${pkgs.system}.lf
];
# Some programs need SUID wrappers, can be configured further or are

View File

@@ -1,5 +1,12 @@
{ inputs, lib, self, ... }: {
flake.nixosModules.main = { pkgs, ... }: {
environment.systemPackages = with pkgs; [
vim
wget
zip
unzip
nix-sweep
];
imports = [
self.nixosModules.git
self.nixosModules.lf
@@ -11,8 +18,11 @@
};
flake.nixosModules.visualProfile = { pkgs, ... }: {
environment.systemPackages = with pkgs; [
zathura
mpv
];
imports = [
self.nixosModules.main
self.nixosModules.niri
self.nixosModules.pipewire
@@ -30,6 +40,8 @@
};
flake.nixosModules.developmentProfile = { pkgs, ... }: {
environment.systemPackages = with pkgs; [
];
imports = [
self.nixosModules.devenv
];

View File

@@ -1,5 +1,5 @@
{
flake.nixosModules.base = {lib, ...}: {
flake.nixosModules.user = {lib, ...}: {
options.preferences = {
user.name = lib.mkOption {
type = lib.types.str;