textproc/py-mkdocstrings: New port
This Python package is an extension for MkDocs and its main purpose is the automation of documentation from sources. Features: * Language-agnostic * Multiple themes support * Cross-references across pages * Cross-references across sites * Inline injection in Markdown * Global and local configuration * Watch source code directories * Reasonable defaults WWW: https://github.com/mkdocstrings/mkdocstrings
This commit is contained in:
parent
4d0c38877a
commit
e30bd8fffa
@ -1368,6 +1368,7 @@
|
||||
SUBDIR += py-mkdocs-material
|
||||
SUBDIR += py-mkdocs-material-extensions
|
||||
SUBDIR += py-mkdocs-nature
|
||||
SUBDIR += py-mkdocstrings
|
||||
SUBDIR += py-mwparserfromhell
|
||||
SUBDIR += py-myst-parser
|
||||
SUBDIR += py-nbsphinx
|
||||
|
40
textproc/py-mkdocstrings/Makefile
Normal file
40
textproc/py-mkdocstrings/Makefile
Normal file
@ -0,0 +1,40 @@
|
||||
PORTNAME= mkdocstrings
|
||||
DISTVERSION= 0.17.0
|
||||
CATEGORIES= textproc python
|
||||
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
||||
|
||||
MAINTAINER= kai@FreeBSD.org
|
||||
COMMENT= Automatic documentation from sources for MkDocs
|
||||
|
||||
LICENSE= ISCL
|
||||
LICENSE_FILE= ${WRKSRC}/LICENSE
|
||||
|
||||
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}Jinja2>=2.11.1:devel/py-Jinja2@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}markdown>=3.3:textproc/py-markdown@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}markupsafe>=1.1:textproc/py-markupsafe@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}mkdocs>=1.2:textproc/py-mkdocs@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}pymdown-extensions>=6.3:textproc/py-pymdown-extensions@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}mkdocs-autorefs>=0.1:textproc/py-mkdocs-autorefs@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}pytkdocs>=0.14.0:textproc/py-pytkdocs@${PY_FLAVOR}
|
||||
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}mkdocs-material>0:textproc/py-sphinx@${PY_FLAVOR} \
|
||||
${PYTHON_PKGNAMEPREFIX}sphinx>0:textproc/py-sphinx@${PY_FLAVOR}
|
||||
|
||||
USES= python:3.6+
|
||||
USE_GITHUB= yes
|
||||
USE_PYTHON= autoplist distutils
|
||||
|
||||
TEST_ENV= PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
|
||||
|
||||
NO_ARCH= yes
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's|%%DISTVERSION%%|${DISTVERSION}|' ${WRKSRC}/setup.py
|
||||
|
||||
# Skip "test_sphinx_load_mkdocstrings_inventory_file" as it requires
|
||||
# mkdocs-gen-files (not in Ports tree, yet).
|
||||
do-test:
|
||||
@cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m pytest -v -rs \
|
||||
-k 'not test_sphinx_load_mkdocstrings_inventory_file'
|
||||
|
||||
.include <bsd.port.mk>
|
3
textproc/py-mkdocstrings/distinfo
Normal file
3
textproc/py-mkdocstrings/distinfo
Normal file
@ -0,0 +1,3 @@
|
||||
TIMESTAMP = 1645976995
|
||||
SHA256 (mkdocstrings-mkdocstrings-0.17.0_GH0.tar.gz) = dcd8f03387c423bb1ddf6fbbec8dfa0432dfc3d01001adb4a0c07985f333971c
|
||||
SIZE (mkdocstrings-mkdocstrings-0.17.0_GH0.tar.gz) = 73551
|
44
textproc/py-mkdocstrings/files/patch-setup.py
Normal file
44
textproc/py-mkdocstrings/files/patch-setup.py
Normal file
@ -0,0 +1,44 @@
|
||||
--- setup.py.orig 2022-02-28 05:29:01 UTC
|
||||
+++ setup.py
|
||||
@@ -0,0 +1,41 @@
|
||||
+# Generated via pdm export -f setuppy" (run "pdm lock" beforehand)
|
||||
+# -*- coding: utf-8 -*-
|
||||
+from setuptools import setup
|
||||
+
|
||||
+INSTALL_REQUIRES = [
|
||||
+ 'Jinja2>=2.11.1',
|
||||
+ 'Markdown>=3.3',
|
||||
+ 'MarkupSafe>=1.1',
|
||||
+ 'mkdocs>=1.2',
|
||||
+ 'mkdocs-autorefs>=0.1',
|
||||
+ 'pymdown-extensions>=6.3',
|
||||
+ 'pytkdocs>=0.14.0',
|
||||
+]
|
||||
+ENTRY_POINTS = {
|
||||
+ 'mkdocs.plugins': [
|
||||
+ 'mkdocstrings = mkdocstrings.plugin:MkdocstringsPlugin',
|
||||
+ ],
|
||||
+}
|
||||
+
|
||||
+setup_kwargs = {
|
||||
+ 'name': 'mkdocstrings',
|
||||
+ 'version': '%%DISTVERSION%%',
|
||||
+ 'description': 'Automatic documentation from sources, for MkDocs.',
|
||||
+ 'author': '',
|
||||
+ 'author_email': 'Timothée Mazzucotelli <pawamoy@pm.me>',
|
||||
+ 'package_dir': {'': 'src/'},
|
||||
+ 'packages': [
|
||||
+ 'mkdocstrings',
|
||||
+ 'mkdocstrings.handlers',
|
||||
+ 'mkdocstrings.templates.python',
|
||||
+ 'mkdocstrings.templates.python.material',
|
||||
+ 'mkdocstrings.templates.python.mkdocs',
|
||||
+ 'mkdocstrings.templates.python.readthedocs'
|
||||
+ ],
|
||||
+ 'package_data': {'': ['*']},
|
||||
+ 'install_requires': INSTALL_REQUIRES,
|
||||
+ 'python_requires': '>=3.6.2',
|
||||
+ 'entry_points': ENTRY_POINTS,
|
||||
+}
|
||||
+
|
||||
+setup(**setup_kwargs)
|
15
textproc/py-mkdocstrings/pkg-descr
Normal file
15
textproc/py-mkdocstrings/pkg-descr
Normal file
@ -0,0 +1,15 @@
|
||||
This Python package is an extension for MkDocs and its main purpose is the
|
||||
automation of documentation from sources.
|
||||
|
||||
Features:
|
||||
|
||||
* Language-agnostic
|
||||
* Multiple themes support
|
||||
* Cross-references across pages
|
||||
* Cross-references across sites
|
||||
* Inline injection in Markdown
|
||||
* Global and local configuration
|
||||
* Watch source code directories
|
||||
* Reasonable defaults
|
||||
|
||||
WWW: https://github.com/mkdocstrings/mkdocstrings
|
Loading…
Reference in New Issue
Block a user