depot/third_party/nixpkgs/pkgs/development/python-modules/rich/default.nix
Default email a6d62be0d1 Project import generated by Copybara.
GitOrigin-RevId: ac169ec6371f0d835542db654a65e0f2feb07838
2021-12-26 18:43:05 +01:00

50 lines
1,005 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, CommonMark
, colorama
, dataclasses
, poetry-core
, pygments
, typing-extensions
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "rich";
version = "10.14.0";
format = "pyproject";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "willmcgugan";
repo = pname;
rev = "v${version}";
sha256 = "1j1m1064gmy07ah4crds5sd0k7dcwvf2b1z6rvjfvq4v9fx962qv";
};
nativeBuildInputs = [ poetry-core ];
propagatedBuildInputs = [
CommonMark
colorama
pygments
typing-extensions
] ++ lib.optional (pythonOlder "3.7") [
dataclasses
];
checkInputs = [
pytestCheckHook
];
pythonImportsCheck = [ "rich" ];
meta = with lib; {
description = "Render rich text, tables, progress bars, syntax highlighting, markdown and more to the terminal";
homepage = "https://github.com/willmcgugan/rich";
license = licenses.mit;
maintainers = with maintainers; [ ris ];
};
}