- Introduced a new package `lidarr-cleanup-singles` to identify and manage duplicate single tracks in Lidarr. - Updated `flake.nix` to include the new package in outputs and modified app definitions to support it. - Created a new script in `src-cleanup` for the main functionality, including audio fingerprint verification. - Added necessary dependencies and configuration in `pyproject.toml` for the new package. - Removed unused `flake-utils` and `systems` entries from `flake.lock` to streamline the configuration.
65 lines
1.6 KiB
Nix
65 lines
1.6 KiB
Nix
{
|
|
description = "Lidarr to MusicBrainz Missing Albums Finder";
|
|
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
|
|
|
outputs =
|
|
{ nixpkgs, self }:
|
|
let
|
|
system = "x86_64-linux";
|
|
pkgs = import nixpkgs { inherit system; };
|
|
inherit (pkgs) lib;
|
|
lidarr-mb-gap = import ./nix/package.nix {
|
|
inherit pkgs;
|
|
src = lib.cleanSource ./src;
|
|
};
|
|
lidarr-cleanup-singles = import ./nix/package-cleanup.nix {
|
|
inherit pkgs;
|
|
src = lib.cleanSource ./src-cleanup;
|
|
};
|
|
in
|
|
{
|
|
nixosModules.lidarr-mb-gap = import ./nixos/lidarr-mb-gap.nix;
|
|
|
|
packages.${system} = {
|
|
default = lidarr-mb-gap;
|
|
inherit lidarr-mb-gap lidarr-cleanup-singles;
|
|
};
|
|
|
|
apps.${system} = {
|
|
default = {
|
|
type = "app";
|
|
program = "${lidarr-mb-gap}/bin/lidarr-mb-gap";
|
|
};
|
|
lidarr-mb-gap = {
|
|
type = "app";
|
|
program = "${lidarr-mb-gap}/bin/lidarr-mb-gap";
|
|
};
|
|
lidarr-cleanup-singles = {
|
|
type = "app";
|
|
program = "${lidarr-cleanup-singles}/bin/lidarr-cleanup-singles";
|
|
};
|
|
};
|
|
|
|
devShells.${system} = {
|
|
default = pkgs.mkShell {
|
|
buildInputs = [
|
|
(pkgs.python3.withPackages (
|
|
ps: with ps; [
|
|
requests
|
|
python-dotenv
|
|
]
|
|
))
|
|
pkgs.black
|
|
pkgs.chromaprint
|
|
];
|
|
shellHook = ''
|
|
echo "Python environment ready!"
|
|
echo "Run: python src/main.py"
|
|
echo "Format code with: black src/"
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
}
|