diff --git a/pkgs/development/python-modules/luhn/default.nix b/pkgs/development/python-modules/luhn/default.nix new file mode 100644 index 000000000000..09ab90a3b177 --- /dev/null +++ b/pkgs/development/python-modules/luhn/default.nix @@ -0,0 +1,36 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, pytestCheckHook +}: + +buildPythonPackage rec { + pname = "luhn"; + version = "0.2.0"; + + src = fetchFromGitHub { + owner = "mmcloughlin"; + repo = pname; + rev = version; + sha256 = "sha256-ZifaCjOVhWdXuzi5n6V+6eVN5vrEHKgUdpSOXoMyR18="; + }; + + checkInputs = [ + pytestCheckHook + ]; + + pytestFlagsArray = [ + "test.py" + ]; + + pythonImportsCheck = [ + "luhn" + ]; + + meta = with lib; { + description = "Python module for generate and verify Luhn check digits"; + homepage = "https://github.com/mmcloughlin/luhn"; + license = with licenses; [ mit ]; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 03afe1e7fe67..89e04e6a0912 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -4609,6 +4609,8 @@ in { luftdaten = callPackage ../development/python-modules/luftdaten { }; + luhn = callPackage ../development/python-modules/luhn { }; + luxor = callPackage ../development/python-modules/luxor { }; luxtronik = callPackage ../development/python-modules/luxtronik { };