diff --git a/pkgs/development/python-modules/keep/default.nix b/pkgs/development/python-modules/keep/default.nix index 6023df467420..249551dc7201 100644 --- a/pkgs/development/python-modules/keep/default.nix +++ b/pkgs/development/python-modules/keep/default.nix @@ -1,40 +1,44 @@ { lib, buildPythonPackage, - fetchPypi, - pygithub, - terminaltables, click, + fetchPypi, + flit-core, + pygithub, requests, + terminaltables3, }: buildPythonPackage rec { pname = "keep"; version = "2.11"; - format = "setuptools"; + pyproject = true; src = fetchPypi { inherit pname version; - sha256 = "sha256-Brwvu/Zevr8sOE3KAwakDDzVMc2VoFxIb1orXAes2U0="; + hash = "sha256-Brwvu/Zevr8sOE3KAwakDDzVMc2VoFxIb1orXAes2U0="; }; - propagatedBuildInputs = [ + build-system = [ flit-core ]; + + dependencies = [ click - requests - terminaltables pygithub + requests + terminaltables3 ]; - # no tests + # Module no tests doCheck = false; + pythonImportsCheck = [ "keep" ]; - meta = with lib; { - homepage = "https://github.com/orkohunter/keep"; - description = "Meta CLI toolkit: Personal shell command keeper and snippets manager"; + meta = { + description = "Meta CLI toolkit to keep personal shell command keeper and manage snippets"; + homepage = "https://github.com/OrkoHunter/keep"; + changelog = "https://github.com/OrkoHunter/keep/releases/tag/${version}"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ ris ]; mainProgram = "keep"; - platforms = platforms.all; - license = licenses.mit; - maintainers = with maintainers; [ ris ]; }; } diff --git a/pkgs/development/python-modules/terminaltables3/default.nix b/pkgs/development/python-modules/terminaltables3/default.nix new file mode 100644 index 000000000000..ea4351ea7007 --- /dev/null +++ b/pkgs/development/python-modules/terminaltables3/default.nix @@ -0,0 +1,58 @@ +{ + lib, + buildPythonPackage, + colorama, + colorclass, + fetchFromGitHub, + poetry-core, + pytest-cov-stub, + pytest-xdist, + pytestCheckHook, + pythonOlder, + termcolor, +}: + +buildPythonPackage rec { + pname = "terminaltables3"; + version = "4.0.0-unstable-2024-07-21"; + pyproject = true; + + disabled = pythonOlder "3.11"; + + src = fetchFromGitHub { + owner = "matthewdeanmartin"; + repo = "terminaltables3"; + #rev = "refs/tags/v${version}"; + rev = "f1c465b36eb9b91a984d8864b21376e7c37075b8"; + hash = "sha256-UcEovh1Eb4QNPwLGDjCphPlJSSkOdhCJ2fK3tuSWOTc="; + }; + + build-system = [ poetry-core ]; + + nativeCheckInputs = [ + colorama + colorclass + pytest-cov-stub + pytest-xdist + pytestCheckHook + termcolor + ]; + + pythonImportsCheck = [ "terminaltables3" ]; + + disabledTests = [ + # Tests are comparing CLI output + "test_color" + "test_colors" + "test_height" + "test_width" + ]; + + meta = { + description = "Generate simple tables in terminals from a nested list of strings"; + homepage = "https://github.com/matthewdeanmartin/terminaltables3"; + changelog = "https://github.com/matthewdeanmartin/terminaltables3/blob/${src.rev}/CHANGELOG.md"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 75fd5b3333f6..6dc85ed24bb2 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -15704,6 +15704,8 @@ self: super: with self; { terminaltables = callPackage ../development/python-modules/terminaltables { }; + terminaltables3 = callPackage ../development/python-modules/terminaltables3 { }; + terminaltexteffects = callPackage ../development/python-modules/terminaltexteffects { }; termplotlib = callPackage ../development/python-modules/termplotlib { };