42 lines
948 B
Nix
42 lines
948 B
Nix
{
|
|
description = "music-light: dev environment (Python + playerctl) for NixOS/Nix";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
|
};
|
|
|
|
outputs = { self, nixpkgs }:
|
|
let
|
|
systems = [
|
|
"x86_64-linux"
|
|
"aarch64-linux"
|
|
];
|
|
|
|
forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system);
|
|
in
|
|
{
|
|
devShells = forAllSystems (system:
|
|
let
|
|
pkgs = import nixpkgs { inherit system; };
|
|
|
|
# Use a stable Python version with good binary coverage for Pillow.
|
|
py = pkgs.python312.withPackages (ps: [
|
|
ps.requests
|
|
ps.pillow
|
|
]);
|
|
in
|
|
{
|
|
default = pkgs.mkShell {
|
|
packages = [
|
|
py
|
|
pkgs.playerctl
|
|
];
|
|
|
|
shellHook = ''
|
|
echo "music-light devShell ready: $(python --version)"
|
|
'';
|
|
};
|
|
});
|
|
};
|
|
}
|
|
|