From 4de5194950dda82279ace5214191c99ded6ea041 Mon Sep 17 00:00:00 2001 From: Laurens Duijvesteijn Date: Tue, 2 Feb 2021 20:08:47 +0100 Subject: [PATCH] pythonPackages.markdown2: 2.3.6 -> 2.4.0 --- .../python-modules/markdown2/default.nix | 20 +++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/markdown2/default.nix b/pkgs/development/python-modules/markdown2/default.nix index b1513d06e58b..b40254f08987 100644 --- a/pkgs/development/python-modules/markdown2/default.nix +++ b/pkgs/development/python-modules/markdown2/default.nix @@ -1,15 +1,23 @@ -{ lib, buildPythonPackage, fetchPypi }: +{ lib, buildPythonPackage, fetchFromGitHub, python, pygments }: buildPythonPackage rec { pname = "markdown2"; - version = "2.3.6"; + version = "2.4.0"; - src = fetchPypi { - inherit pname version; - extension = "zip"; - sha256 = "08a124043aa0ad36ba2136239547d5011a2b770278abb11a5609611e0040ea05"; + # PyPI does not contain tests, so using GitHub instead. + src = fetchFromGitHub { + owner = "trentm"; + repo = "python-markdown2"; + rev = version; + sha256 = "sha256:03qmf087phpj0h9hx111k4r5pkm48dhb61mqhp1v75gd09k0z79z"; }; + checkInputs = [ pygments ]; + + checkPhase = '' + ${python.interpreter} ./test/test.py + ''; + meta = with lib; { description = "A fast and complete Python implementation of Markdown"; homepage = "https://github.com/trentm/python-markdown2";