Refactor NixOS module and flake configuration for lidarr-mb-gap

- Updated `flake.nix` to streamline output definitions and improve readability.
- Refactored NixOS module configurations in `nixos/lidarr-mb-gap.nix` for better structure and clarity.
- Simplified the package import process in `nix/package.nix` by removing unnecessary parameters.
- Enhanced example configurations in `nixos/EXAMPLE_CONFIG.nix` to align with the new structure.
This commit is contained in:
Danilo Reyes
2025-11-11 15:46:42 -06:00
parent 35e6c7e330
commit f3f154d1b0
4 changed files with 75 additions and 61 deletions

View File

@@ -6,7 +6,8 @@
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
outputs =
{ nixpkgs, flake-utils }:
let
# NixOS module output (not system-specific)
# The module accepts a package option, which can be set from the flake's packages
@@ -17,7 +18,9 @@
{
# Export NixOS modules
nixosModules = nixosModules;
} // flake-utils.lib.eachDefaultSystem (system:
}
// flake-utils.lib.eachDefaultSystem (
system:
let
pkgs = import nixpkgs { inherit system; };
lib = pkgs.lib;
@@ -29,10 +32,12 @@
{
devShells.default = pkgs.mkShell {
buildInputs = [
(pkgs.python3.withPackages (ps: with ps; [
requests
python-dotenv
]))
(pkgs.python3.withPackages (
ps: with ps; [
requests
python-dotenv
]
))
pkgs.black
];
shellHook = ''
@@ -55,4 +60,3 @@
}
);
}