[arch-commits] Commit in python-pallets-sphinx-themes/repos/community-any (3 files)
Evangelos Foutras
foutrelis at gemini.archlinux.org
Tue May 24 12:45:55 UTC 2022
Date: Tuesday, May 24, 2022 @ 12:45:55
Author: foutrelis
Revision: 1210194
archrelease: copy trunk to community-any
Added:
python-pallets-sphinx-themes/repos/community-any/PKGBUILD
(from rev 1210193, python-pallets-sphinx-themes/trunk/PKGBUILD)
python-pallets-sphinx-themes/repos/community-any/jinja2-deprecations.patch
(from rev 1210193, python-pallets-sphinx-themes/trunk/jinja2-deprecations.patch)
Deleted:
python-pallets-sphinx-themes/repos/community-any/PKGBUILD
---------------------------+
PKGBUILD | 66 ++++++++++++++++++++++++--------------------
jinja2-deprecations.patch | 66 ++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 103 insertions(+), 29 deletions(-)
Deleted: PKGBUILD
===================================================================
--- PKGBUILD 2022-05-24 12:45:50 UTC (rev 1210193)
+++ PKGBUILD 2022-05-24 12:45:55 UTC (rev 1210194)
@@ -1,29 +0,0 @@
-# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
-
-pkgname=python-pallets-sphinx-themes
-_pyname=${pkgname/python-/}
-pkgver=2.0.1
-pkgrel=3
-pkgdesc='Sphinx themes for Pallets and related projects'
-url='https://github.com/pallets/pallets-sphinx-themes'
-arch=('any')
-license=('BSD')
-depends=('python' 'python-sphinx' 'python-importlib-metadata')
-makedepends=('python-setuptools')
-source=(https://github.com/pallets/pallets-sphinx-themes/archive/${pkgver}/${_pyname}-${pkgver}.tar.gz)
-sha512sums=('6e16ead8bb489336f8b8fe7e50d1e65acf950ab64c90ba1508ceb07bd598d8ddd5b960d9b31697867ddb7bffa970a08d7d53b778b5eec5e01b7c07babf2d5de6')
-b2sums=('6fc745ffc5d344cd542f1b299ef5151144a13d1f75923398d42a6882d3c80aca4827123a3bd1f751dd771e882170c76f5bad99ad42d09dec2a9baf474d846365')
-
-build() {
- cd ${_pyname}-${pkgver}
- python setup.py build
-}
-
-package() {
- cd ${_pyname}-${pkgver}
- python setup.py install -O1 --root="${pkgdir}" --skip-build
- install -Dm 644 LICENSE.rst -t "${pkgdir}/usr/share/licenses/${pkgname}"
- install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
-}
-
-# vim: ts=2 sw=2 et:
Copied: python-pallets-sphinx-themes/repos/community-any/PKGBUILD (from rev 1210193, python-pallets-sphinx-themes/trunk/PKGBUILD)
===================================================================
--- PKGBUILD (rev 0)
+++ PKGBUILD 2022-05-24 12:45:55 UTC (rev 1210194)
@@ -0,0 +1,37 @@
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
+
+pkgname=python-pallets-sphinx-themes
+_pyname=${pkgname/python-/}
+pkgver=2.0.1
+pkgrel=4
+pkgdesc='Sphinx themes for Pallets and related projects'
+url='https://github.com/pallets/pallets-sphinx-themes'
+arch=('any')
+license=('BSD')
+depends=('python' 'python-sphinx' 'python-importlib-metadata')
+makedepends=('python-setuptools')
+source=(https://github.com/pallets/pallets-sphinx-themes/archive/${pkgver}/${_pyname}-${pkgver}.tar.gz
+ jinja2-deprecations.patch)
+sha512sums=('6e16ead8bb489336f8b8fe7e50d1e65acf950ab64c90ba1508ceb07bd598d8ddd5b960d9b31697867ddb7bffa970a08d7d53b778b5eec5e01b7c07babf2d5de6'
+ '55009d31e2a0d41b8e2a3e9f69024f283935913589059069ab999ca706ff8fc914e1f7156db9c832091fb771b2c98eb54373d4c3393d439fbbcfd382fa521bec')
+b2sums=('6fc745ffc5d344cd542f1b299ef5151144a13d1f75923398d42a6882d3c80aca4827123a3bd1f751dd771e882170c76f5bad99ad42d09dec2a9baf474d846365'
+ '3b5550c6b0703158abe99f61a1363f233b95265c247e55360d53c83023f473f22c11b832d0fbd4164d7906b6bc50ad90b3b398f8adeed5ab92f651910f0c6b35')
+
+prepare() {
+ cd ${_pyname}-${pkgver}
+ patch -Np1 -i ../jinja2-deprecations.patch
+}
+
+build() {
+ cd ${_pyname}-${pkgver}
+ python setup.py build
+}
+
+package() {
+ cd ${_pyname}-${pkgver}
+ python setup.py install -O1 --root="${pkgdir}" --skip-build
+ install -Dm 644 LICENSE.rst -t "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+}
+
+# vim: ts=2 sw=2 et:
Copied: python-pallets-sphinx-themes/repos/community-any/jinja2-deprecations.patch (from rev 1210193, python-pallets-sphinx-themes/trunk/jinja2-deprecations.patch)
===================================================================
--- jinja2-deprecations.patch (rev 0)
+++ jinja2-deprecations.patch 2022-05-24 12:45:55 UTC (rev 1210194)
@@ -0,0 +1,66 @@
+From 02d9e0fc53128fbdaf7c71d766832c8613797f20 Mon Sep 17 00:00:00 2001
+From: David Lord <davidism at gmail.com>
+Date: Wed, 10 Nov 2021 09:10:41 -0800
+Subject: [PATCH] compat for jinja 2.0 deprecations
+
+---
+ CHANGES.rst | 1 +
+ src/pallets_sphinx_themes/versions.py | 15 ++++++---------
+ 2 files changed, 7 insertions(+), 9 deletions(-)
+
+diff --git a/src/pallets_sphinx_themes/versions.py b/src/pallets_sphinx_themes/versions.py
+index e95256b..95a4811 100644
+--- a/src/pallets_sphinx_themes/versions.py
++++ b/src/pallets_sphinx_themes/versions.py
+@@ -1,9 +1,8 @@
+-import io
+ import json
+ import os
+ from collections import namedtuple
+
+-from jinja2 import contextfunction
++from jinja2 import pass_context
+ from packaging import version as pv
+
+ from .theme_check import only_pallets_theme
+@@ -27,7 +26,7 @@ def local_versions(app):
+
+ if isinstance(config_versions, str):
+ if os.path.isfile(config_versions):
+- with io.open(config_versions, "rt", encoding="utf8") as f:
++ with open(config_versions, encoding="utf8") as f:
+ config_versions = json.load(f)
+ else:
+ config_versions = json.loads(config_versions)
+@@ -97,7 +96,7 @@ def readthedocs_versions(app):
+
+
+ def _is_version(value, placeholder="x"):
+- if value.endswith(".{}".format(placeholder)):
++ if value.endswith(f".{placeholder}"):
+ value = value[: -(len(placeholder) + 1)]
+
+ try:
+@@ -119,11 +118,9 @@ def __new__(cls, name, slug=None, latest=False, dev=False, current=False):
+ if _is_version(slug):
+ name = "Version " + name
+
+- return super(DocVersion, cls).__new__(
+- cls, name, slug, version, latest, dev, current
+- )
++ return super().__new__(cls, name, slug, version, latest, dev, current)
+
+- @contextfunction
++ @pass_context
+ def href(self, context):
+ pathto = context["pathto"]
+ master_doc = context["master_doc"]
+@@ -134,7 +131,7 @@ def href(self, context):
+ path = builder.get_target_uri(pagename)
+ return "/".join((master, "..", self.slug, path))
+
+- @contextfunction
++ @pass_context
+ def banner(self, context):
+ if self.latest:
+ return
More information about the arch-commits
mailing list