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:
18
flake.nix
18
flake.nix
@@ -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 @@
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user