Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / mdformat-admon / default.nix
bloba7fd0f940373b91fffc2fbd2cbd1fa8aa9cdeea6
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , mdformat
5 , python3
6 , pythonOlder
7 }:
9 let
10   python = python3.override {
11     packageOverrides = self: super: {
12       mdit-py-plugins = super.mdit-py-plugins.overridePythonAttrs (_prev: rec {
13       version = "0.4.0";
14       doCheck = false;
15       src = fetchFromGitHub {
16         owner = "executablebooks";
17         repo = "mdit-py-plugins";
18         rev = "refs/tags/v${version}";
19         hash = "sha256-YBJu0vIOD747DrJLcqiZMHq34+gHdXeGLCw1OxxzIJ0=";
20       };
21     });
22     };
23   };
24 in python.pkgs.buildPythonPackage rec {
25   pname = "mdformat-admon";
26   version = "1.0.2";
27   format = "pyproject";
29   disabled = pythonOlder "3.7";
31   src = fetchFromGitHub {
32     owner = "KyleKing";
33     repo = pname;
34     rev = "v${version}";
35     hash = "sha256-33Q3Re/axnoOHZ9XYA32mmK+efsSelJXW8sD7C1M/jU=";
36   };
38   nativeBuildInputs = with python.pkgs; [
39     flit-core
40   ];
42   buildInputs = with python.pkgs; [
43     mdformat
44   ];
46   propagatedBuildInputs = with python.pkgs; [
47     mdit-py-plugins
48   ];
50   meta = with lib; {
51     description = "mdformat plugin for admonitions";
52     homepage = "https://github.com/KyleKing/mdformat-admon";
53     license = licenses.mit;
54     maintainers = with maintainers; [ aldoborrero ];
55   };