nix: allow passing extra python packages

I wanted to use
https://github.com/9001/copyparty/blob/hovudstraum/bin/hooks/notify.py
but that wasn't really possible without this under the nix package.
This commit is contained in:
Tom van Dijk 2025-07-28 12:42:29 +02:00
parent 20e1a3c93a
commit e278316615
No known key found for this signature in database
GPG key ID: 7A984C8207ADBA51

View file

@ -33,6 +33,11 @@ withSMB ? false,
# extra packages to add to the PATH # extra packages to add to the PATH
extraPackages ? [ ], extraPackages ? [ ],
# function that accepts a python packageset and returns a list of packages to
# be added to the python venv. useful for scripts and such that require
# additional dependencies
extraPythonPackages ? (_p: [ ]),
}: }:
let let
@ -50,6 +55,7 @@ let
++ lib.optional withBasicAudioMetadata mutagen ++ lib.optional withBasicAudioMetadata mutagen
++ lib.optional withHashedPasswords argon2-cffi ++ lib.optional withHashedPasswords argon2-cffi
++ lib.optional withZeroMQ pyzmq ++ lib.optional withZeroMQ pyzmq
++ (extraPythonPackages ps)
); );
in stdenv.mkDerivation { in stdenv.mkDerivation {
pname = "copyparty"; pname = "copyparty";