From c5dd41afc6659b96c86efea512ee7ecc0bbf6604 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Mon, 2 May 2022 00:47:24 -0400 Subject: gnu: Add python-mf2py. * gnu/packages/python-web.scm (python-mf2py): New variable. --- gnu/packages/python-web.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'gnu/packages') diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 00fe560a36..59828d7473 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -7409,3 +7409,35 @@ with @code{html_text} does not contain elements such as JavaScript or inline styles not normally visible to users. It also normalizes white space characters in a smarter, more visually pleasing style.") (license license:expat))) + +(define-public python-mf2py + (package + (name "python-mf2py") + (version "1.1.2") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/microformats/mf2py") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "00pzfc5sl6ywlcr6f2k37n3f2bb7w488p2k95ixzjwx6w3yh747n")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest" "-vv" "test"))))))) + (native-inputs (list python-pytest)) + (propagated-inputs + (list python-beautifulsoup4 python-html5lib python-requests)) + (home-page "https://github.com/microformats/mf2py") + (synopsis "Python Microformats2 parser") + (description "This Python library provides a Microformats2 parser +implementing the full Microformats2 (mf2) specification, including backward +compatibility with Microformats1 (mf1).") + (license license:expat))) -- cgit v1.2.3