commit ea297266c864745371367661c36014d5dfc33b73 parent 78d5f1701900f4de8be7aa9255167a4fa266ea14 Author: Nikolay Korotkiy <sikmir@disroot.org> Date: Sat, 8 Oct 2022 14:53:17 +0300 Add rst2txt Diffstat:
M | pkgs/default.nix | | | 1 | + |
A | pkgs/misc/rst2txt/default.nix | | | 31 | +++++++++++++++++++++++++++++++ |
2 files changed, 32 insertions(+), 0 deletions(-)
diff --git a/pkgs/default.nix b/pkgs/default.nix @@ -333,6 +333,7 @@ lib.makeScope newScope ( qasync = callPackage ./misc/qasync { }; qoiview = callPackage ./misc/qoiview { }; repolocli = callPackage ./misc/repolocli { }; + rst2txt = callPackage ./misc/rst2txt { }; sdorfehs = callPackage ./misc/sdorfehs { }; serverpp = callPackage ./misc/serverpp { }; taskcoach = callPackage ./misc/taskcoach { }; diff --git a/pkgs/misc/rst2txt/default.nix b/pkgs/misc/rst2txt/default.nix @@ -0,0 +1,31 @@ +{ lib, fetchFromGitHub, python3Packages }: + +python3Packages.buildPythonApplication rec { + pname = "rst2txt"; + version = "1.1.0"; + + src = fetchFromGitHub { + owner = "stephenfin"; + repo = "rst2txt"; + rev = version; + hash = "sha256-UqY+qD1S8tyRxvQ0GIzfBlHzsdVSaEJkmgw1WC0H/KA="; + }; + + nativeBuildInputs = with python3Packages; [ setuptools-scm ]; + + SETUPTOOLS_SCM_PRETEND_VERSION = version; + + propagatedBuildInputs = with python3Packages; [ + pygments + setuptools # pkg_resources + ]; + + doCheck = false; + + meta = with lib; { + description = "Convert reStructuredText to plain text"; + inherit (src.meta) homepage; + license = licenses.bsd2; + maintainers = [ maintainers.sikmir ]; + }; +}