c594a97518
GitOrigin-RevId: 301aada7a64812853f2e2634a530ef5d34505048
72 lines
1.2 KiB
Nix
72 lines
1.2 KiB
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchPypi
|
|
, setuptools
|
|
, docutils
|
|
, importlib-metadata
|
|
, jinja2
|
|
, packaging
|
|
, pygments
|
|
, pyyaml
|
|
, reportlab
|
|
, smartypants
|
|
, pillow
|
|
, pytestCheckHook
|
|
, pymupdf
|
|
, sphinx
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "rst2pdf";
|
|
version = "0.99";
|
|
|
|
format = "pyproject";
|
|
|
|
src = fetchPypi {
|
|
inherit pname version;
|
|
sha256 = "8fa23fa93bddd1f52d058ceaeab6582c145546d80f2f8a95974f3703bd6c8152";
|
|
};
|
|
|
|
outputs = [ "out" "man" ];
|
|
|
|
nativeBuildInputs = [
|
|
setuptools
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
docutils
|
|
importlib-metadata
|
|
jinja2
|
|
packaging
|
|
pygments
|
|
pyyaml
|
|
reportlab
|
|
smartypants
|
|
pillow
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"rst2pdf"
|
|
];
|
|
|
|
checkInputs = [
|
|
pytestCheckHook
|
|
pymupdf
|
|
sphinx
|
|
];
|
|
|
|
# Test suite fails: https://github.com/rst2pdf/rst2pdf/issues/1067
|
|
doCheck = false;
|
|
|
|
postInstall = ''
|
|
mkdir -p $man/share/man/man1/
|
|
${docutils}/bin/rst2man.py doc/rst2pdf.rst $man/share/man/man1/rst2pdf.1
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Convert reStructured Text to PDF via ReportLab";
|
|
homepage = "https://rst2pdf.org/";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ marsam ];
|
|
};
|
|
}
|