diff --git a/www/Makefile b/www/Makefile --- a/www/Makefile +++ b/www/Makefile @@ -1663,6 +1663,7 @@ SUBDIR += py-flask-compress SUBDIR += py-flask-cors SUBDIR += py-flask-flatpages + SUBDIR += py-flask-gravatar SUBDIR += py-flask-json SUBDIR += py-flask-jwt-extended SUBDIR += py-flask-limiter diff --git a/www/py-flask-gravatar/Makefile b/www/py-flask-gravatar/Makefile new file mode 100644 --- /dev/null +++ b/www/py-flask-gravatar/Makefile @@ -0,0 +1,49 @@ +PORTNAME= Flask-Gravatar +DISTVERSION= 0.5.0 +CATEGORIES= www python +MASTER_SITES= PYPI +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= agh@riseup.net +COMMENT= Small and simple Gravatar integration with Flask +WWW= https://pypi.org/project/Flask-Gravatar/ + +LICENSE= BSD3CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}setuptools>0:devel/py-setuptools@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}sphinx>0:textproc/py-sphinx@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}flask>0:www/py-flask@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}wheel>0:devel/py-wheel@${PY_FLAVOR} + +USES= python +USE_PYTHON= autoplist pep517 + +DOCSDIR= ${PREFIX}/share/doc/${PYTHON_PKGNAMEPREFIX}${PORTNAME} + +NO_ARCH= yes + +PLIST_FILES= share/man/man1/${PORTNAME:C|-||:tl}.1.gz +PORTDOCS= * + +OPTIONS_DEFINE= DOCS + +do-build-DOCS-on: + (cd ${WRKSRC} && \ + ${SETENV} sphinx-build-${PYTHON_VER} -b html docs docs/_build/html) + +post-build: + (cd ${WRKSRC} && \ + ${SETENV} sphinx-build-${PYTHON_VER} -b man docs docs/_build/man) + +post-install: + ${INSTALL_MAN} ${WRKSRC}/docs/_build/man/${PORTNAME:C|-||:tl}.1 \ + ${STAGEDIR}${PREFIX}/share/man/man1/ + +post-install-DOCS-on: + ${MKDIR} ${STAGEDIR}${DOCSDIR} + (cd ${WRKSRC}/docs/_build/html && \ + ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}/ "-not -name .buildinfo -not -regex ^./.doctrees.* -not -regex ^./_sources.*") + +.include diff --git a/www/py-flask-gravatar/distinfo b/www/py-flask-gravatar/distinfo new file mode 100644 --- /dev/null +++ b/www/py-flask-gravatar/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1703254457 +SHA256 (Flask-Gravatar-0.5.0.tar.gz) = 60665f31c2c612891db68ff801e93ed3a0881c6c8ec346abc64d2a9923f562e1 +SIZE (Flask-Gravatar-0.5.0.tar.gz) = 17299 diff --git a/www/py-flask-gravatar/files/patch-setup.cfg b/www/py-flask-gravatar/files/patch-setup.cfg new file mode 100644 --- /dev/null +++ b/www/py-flask-gravatar/files/patch-setup.cfg @@ -0,0 +1,16 @@ + Use of 'force_manifest' is deprecated. + +--- setup.cfg.orig 2023-12-27 12:06:35 UTC ++++ setup.cfg +@@ -10,9 +10,9 @@ universal = 1 + universal = 1 + + [sdist] +-force-manifest = 1 ++force_manifest = 1 + + [egg_info] +-tag_build = ++tag_build = + tag_date = 0 + diff --git a/www/py-flask-gravatar/files/patch-setup.py b/www/py-flask-gravatar/files/patch-setup.py new file mode 100644 --- /dev/null +++ b/www/py-flask-gravatar/files/patch-setup.py @@ -0,0 +1,12 @@ + Deprecated pytest-runner is not required. + +--- setup.py.orig 2023-12-27 12:00:27 UTC ++++ setup.py +@@ -39,7 +39,6 @@ setup_requires = [ + extras_require['all'].extend(reqs) + + setup_requires = [ +- 'pytest-runner>=2.6.2', + ] + + install_requires = [ diff --git a/www/py-flask-gravatar/pkg-descr b/www/py-flask-gravatar/pkg-descr new file mode 100644 --- /dev/null +++ b/www/py-flask-gravatar/pkg-descr @@ -0,0 +1,5 @@ +Flask-Gravatar is a small and simple Python Flask module for integrating with +the Gravatar service. + +Gravatar is a service providing providing globally unique avatars, based on +users' email, and an image of their choice.