2021-04-26 19:14:03 +00:00
|
|
|
{ lib, fetchFromGitHub, buildPythonPackage, pyyaml, six, pytest, pyaml }:
|
2020-12-03 08:41:04 +00:00
|
|
|
|
2021-04-26 19:14:03 +00:00
|
|
|
buildPythonPackage rec {
|
2020-12-03 08:41:04 +00:00
|
|
|
pname = "python-frontmatter";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "1.0.1";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2020-12-03 08:41:04 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "eyeseast";
|
|
|
|
repo = pname;
|
2023-11-16 04:20:00 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
sha256 = "sha256-lkBCKZ1fZF580+4TnHYkfaGJjsWk7/Ksnk7VagZuef8=";
|
2020-12-03 08:41:04 +00:00
|
|
|
};
|
|
|
|
|
2021-04-26 19:14:03 +00:00
|
|
|
propagatedBuildInputs = [
|
2020-12-03 08:41:04 +00:00
|
|
|
pyyaml
|
2021-04-26 19:14:03 +00:00
|
|
|
pyaml # yes, it's needed
|
2020-12-03 08:41:04 +00:00
|
|
|
six
|
|
|
|
];
|
|
|
|
|
2021-04-26 19:14:03 +00:00
|
|
|
# tries to import test.test, which conflicts with module
|
|
|
|
# exported by python interpreter
|
|
|
|
doCheck = false;
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2020-12-03 08:41:04 +00:00
|
|
|
pytest
|
|
|
|
];
|
|
|
|
|
2021-04-26 19:14:03 +00:00
|
|
|
pythonImportsCheck = [ "frontmatter" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-12-03 08:41:04 +00:00
|
|
|
homepage = "https://github.com/eyeseast/python-frontmatter";
|
|
|
|
description = "Parse and manage posts with YAML (or other) frontmatter";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ siraben ];
|
2021-04-26 19:14:03 +00:00
|
|
|
platforms = platforms.unix;
|
2020-12-03 08:41:04 +00:00
|
|
|
};
|
|
|
|
}
|