2017-07-15 08:51:07 +01:00
|
|
|
{ stdenv, buildPythonPackage, fetchPypi
|
|
|
|
, pip, pandoc, glibcLocales, haskellPackages, texlive }:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pypandoc";
|
2017-08-24 18:34:20 +01:00
|
|
|
version = "1.4";
|
2017-07-15 08:51:07 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2017-08-24 18:34:20 +01:00
|
|
|
sha256 = "e914e6d5f84a76764887e4d909b09d63308725f0cbb5293872c2c92f07c11a5b";
|
2017-07-15 08:51:07 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
# Fix tests: first requires network access, second is a bug (reported upstream)
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace tests.py --replace "pypandoc.convert(url, 'html')" "'GPL2 license'"
|
|
|
|
substituteInPlace tests.py --replace "pypandoc.convert_file(file_name, lua_file_name)" "'<h1 id=\"title\">title</h1>'"
|
|
|
|
'';
|
|
|
|
|
|
|
|
LC_ALL="en_US.UTF-8";
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ pip ];
|
|
|
|
|
|
|
|
buildInputs = [ pandoc texlive.combined.scheme-small haskellPackages.pandoc-citeproc glibcLocales ];
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Thin wrapper for pandoc";
|
2017-08-01 21:03:30 +01:00
|
|
|
homepage = https://github.com/bebraw/pypandoc;
|
2017-07-15 08:51:07 +01:00
|
|
|
license = licenses.mit;
|
2018-02-02 18:16:39 +00:00
|
|
|
maintainers = with maintainers; [ bennofs ];
|
2018-02-19 22:05:47 +00:00
|
|
|
|
|
|
|
broken = true; # incompatible with pandoc v2
|
2017-07-15 08:51:07 +01:00
|
|
|
};
|
|
|
|
}
|