From 267ec7909fb58134da081d4192bd673c7112c664 Mon Sep 17 00:00:00 2001 From: lychee Date: Sun, 11 Feb 2024 12:44:35 -0600 Subject: [PATCH] python3Packages.jishaku: init at 2.5.2 --- .../python-modules/jishaku/default.nix | 66 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 68 insertions(+) create mode 100644 pkgs/development/python-modules/jishaku/default.nix diff --git a/pkgs/development/python-modules/jishaku/default.nix b/pkgs/development/python-modules/jishaku/default.nix new file mode 100644 index 000000000000..e758f4c691eb --- /dev/null +++ b/pkgs/development/python-modules/jishaku/default.nix @@ -0,0 +1,66 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + fetchpatch, + setuptools, + discordpy, + click, + braceexpand, + import-expression, + tabulate, + pytestCheckHook, + pytest-asyncio, + youtube-dl +}: +buildPythonPackage rec { + pname = "jishaku"; + version = "2.5.2"; + pyproject = true; + + src = fetchFromGitHub { + owner = "Gorialis"; + repo = pname; + rev = "refs/tags/${version}"; + hash = "sha256-BWnuk6h80cKwRECyTuRvnYnTC78219oraeTNoqWDd1c="; + }; + + patches = [ + (fetchpatch { + # add entrypoint for install script + url = "https://github.com/Gorialis/jishaku/commit/b96cd55a1c2fd154c548f08019ccd6f7be9c7f90.patch"; + hash = "sha256-laPoupwCC1Zthib8G+c1BXqTwZK0Z6up1DKVkhFicJ0="; + }) + ]; + + nativeBuildInputs = [ setuptools ]; + + propagatedBuildInputs = [ + discordpy + click + braceexpand + tabulate + import-expression + ]; + + nativeCheckInputs = [ + pytestCheckHook + pytest-asyncio + youtube-dl + ]; + + pythonImportsCheck = [ + "jishaku" + "jishaku.repl" + "jishaku.features" + ]; + + meta = { + description = "A debugging and testing cog for discord.py bots"; + homepage = "https://jishaku.readthedocs.io/en/latest"; + changelog = "https://github.com/Gorialis/jishaku/releases/tag/${version}"; + maintainers = with lib.maintainers; [ lychee ]; + mainProgram = "jishaku"; + license = lib.licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 31453e22038e..a281e75d928b 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5861,6 +5861,8 @@ self: super: with self; { jira = callPackage ../development/python-modules/jira { }; + jishaku = callPackage ../development/python-modules/jishaku { }; + jiwer = callPackage ../development/python-modules/jiwer { }; jmespath = callPackage ../development/python-modules/jmespath { };