This commit is contained in:
Jonas Rabenstein 2025-11-29 18:14:10 +01:00
commit 794925acb2
15 changed files with 516 additions and 529 deletions

View file

@ -0,0 +1,35 @@
{
lib,
fetchFromGitHub,
newScope,
}@args:
let
fetchJellyfinPlugin = (lib.makeScope newScope (_: args)).callPackage package;
package =
{
name,
fetchFromGitHub,
...
}@args:
let
self = fetchJellyfinPlugin args;
extraArgs = lib.attrsets.removeAttrs args (builtins.attrNames (lib.functionArgs package));
owner = args.owner or "jellyfin";
repo = args.repo or "jellyfin-plugin-${args.name}";
name = builtins.concatStringsSep "-" (
[ repo ] ++ lib.optional (args ? version) args.version ++ [ "source" ]
);
in
fetchFromGitHub (
{
inherit owner repo name;
passthru.override = self.override;
}
// extraArgs
);
in
fetchJellyfinPlugin