Merge commit '101d7f8'

This commit is contained in:
Kujiu 2023-08-13 16:54:13 +02:00
commit 8ac04991ac
Signed by: kujiu
GPG key ID: ABBB2CAC6855599F
17 changed files with 109 additions and 117 deletions

View file

@ -1,6 +1,11 @@
Changes
#######
2.0.0 (*2023-08-11*)
~~~~~~~~~~~~~~~~~~~~
- Python 3.11 and Sphinx 7.0 support
1.1.0 (*2021-08-03*)
~~~~~~~~~~~~~~~~~~~~

View file

@ -1,2 +0,0 @@
include VERSION
include CHANGES

View file

@ -1,21 +0,0 @@
PYTHON = python3
SRCDIR = .
DISTDIR = ./dist
BUILDDIR = ./build
all: sdist wheel
clean:
rm -rf *.egg-info dist build
sdist:
$(PYTHON) -m build $(SRCDIR) -o $(DISTDIR) -sn
wheel:
$(PYTHON) -m build $(SRCDIR) -o $(BUILDDIR) -wn
install:
pip uninstall -y sphinx-galleria
pip install $(DISTDIR)/sphinx_galleria-`cat $(SRCDIR)/VERSION`.tar.gz
.PHONY: clean sdist wheel install

View file

@ -1 +0,0 @@
1.1.0

View file

@ -1,6 +1,102 @@
[build-system]
requires = [
"setuptools>=56",
"wheel"
requires = ["flit_core>=3.2"]
build-backend = "flit_core.buildapi"
[project]
name = "sphinx_galleria"
version = "2.0.0"
requires-python = ">=3.8"
dependencies = [
"Sphinx>=7.0.0",
"Pillow"
]
license = {text = "EUPL-1.2"}
authors = [
{name = "Nerv Project ASBL", email = "contact@nerv-project.eu"},
{name = "kujiu"},
{name = "ptitgnu"}
]
maintainers = [
{name = "Nerv Project ASBL", email = "contact@nerv-project.eu"},
{name = "kujiu"},
{name = "ptitgnu"}
]
description = "Create image galleries with Sphinx"
readme = {file = "README.rst", content-type = "text/x-rst"}
keywords=["sphinx", "doc", "theme"]
classifiers=[
"Framework :: Sphinx",
"Framework :: Sphinx :: Theme",
"Development Status :: 5 - Production/Stable",
"License :: OSI Approved :: European Union Public Licence 1.2 (EUPL 1.2)",
"Environment :: Console",
"Environment :: Web Environment",
"Framework :: Sphinx :: Theme",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3",
"Operating System :: OS Independent",
"Topic :: Documentation",
"Topic :: Software Development :: Documentation",
]
[project.urls]
homepage = "https://www.nerv-project.eu"
repository = "https://procrastinator.nerv-project.eu/nerv-project/sphinx_galleria"
issues = "https://procrastinator.nerv-project.eu/nerv-project/sphinx_galleria/issues"
editor = "https://www.nerv-project.eu"
changelog = "https://procrastinator.nerv-project.eu/nerv-project/sphinx_galleria/raw/branch/main/CHANGES.rst"
[project.optional-dependencies]
tests = [
"pytest",
"flake8",
"pylint",
"pytest-cov"
]
setup = [
"Sphinx",
"pytest-runner",
"flake8",
"pylint",
"babel",
"flit",
]
[project.scripts]
[tool.pytest.ini_options]
minversion = "6.0"
addopts = "-ra -q"
testpaths = [
"tests",
]
[tool.babel.extract_messages]
mapping_file = "babel.cfg"
output_file = "locale/sphinx.pot"
keywords = ["_", "__", "l_", "lazy_gettext", "gettext", "ngettext"]
add_comments = "Translators:"
[tool.babel.init_catalog]
domain = "sphinx"
input_file = "locale/sphinx.pot"
output_dir = "locale/"
[tool.babel.update_catalog]
domain = "sphinx"
input_file = "locale/sphinx.pot"
output_dir = "locale/"
[tool.babel.compile_catalog]
domain = "sphinx"
directory = "locale/"
[tool.flit.sdist]
include = [
"*.py",
"static/sphinxgalleria/*.mjs",
"static/sphinxgalleria/*.css",
"locale/*.pot",
"locale/*/LC_MESSAGES/*.po",
"locale/*/LC_MESSAGES/*.mo"
]
build-backend = "setuptools.build_meta"

View file

@ -1,4 +0,0 @@
Sphinx
Pillow
setuptools>=56
build

View file

@ -1,78 +0,0 @@
[metadata]
long_description = file: README.rst, CHANGES.rst
long_description_content_type = text/x-rst
license_files =
LICENSE
LICENSE-de
LICENSE-fr
LICENSE-nl
name = sphinx_galleria
version = file: VERSION
url = https://procrastinator.nerv-project.eu/nerv-project/sphinx_galleria
license = EUPL 1.2
author = Kujiu
author_email = kujiu-pypi@kujiu.org
description = Create image galleries with Sphinx
platform = any
classifiers =
Framework :: Sphinx
Framework :: Sphinx :: Extension
Development Status :: 5 - Production/Stable
Environment :: Console
Environment :: Web Environment
Intended Audience :: Developers
License :: OSI Approved :: European Union Public Licence 1.2 (EUPL 1.2)
Programming Language :: Python :: 3
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Operating System :: OS Independent
Topic :: Documentation
Topic :: Software Development :: Documentation
keywords = sphinx image gallery
project_urls =
Source Code = https://procrastinator.nerv-project.eu/nerv-project/sphinx_galleria
Bug Tracker = https://procrastinator.nerv-project.eu/nerv-project/sphinx_galleria/issues
[options]
install_requires =
Sphinx>=3.0.0
Pillow
packages = sphinx_galleria
package_dir =
sphinx_galleria = .
# cmdclass =
# compile_catalog = babel.messages.frontend.compile_catalog,
# extract_messages = babel.messages.frontend.extract_messages,
# init_catalog = babel.messages.frontend.init_catalog,
# update_catalog = babel.messages.frontend.update_catalog
[options.package_data]
sphinx_galleria =
VERSION
static/sphinxgalleria/*.mjs
static/sphinxgalleria/*.css
locale/*.pot
locale/*/LC_MESSAGES/*.po
locale/*/LC_MESSAGES/*.mo
[extract_messages]
mapping_file = babel.cfg
output_file = sphinx_galleria/locale/sphinx.pot
keywords = _ __ l_ lazy_gettext gettext ngettext
add_comments = Translators:
[init_catalog]
domain = sphinx
input_file = sphinx_galleria/locale/sphinx.pot
output_dir = sphinx_galleria/locale/
[update_catalog]
domain = sphinx
input_file = sphinx_galleria/locale/sphinx.pot
output_dir = sphinx_galleria/locale/
[compile_catalog]
domain = sphinx
directory = sphinx_galleria/locale/

View file

@ -5,6 +5,7 @@
Create image galleries
"""
import os
from typing import Dict, Any
from sphinx.application import Sphinx
from sphinx.environment import BuildEnvironment
@ -14,13 +15,9 @@ from PIL import Image
from sphinx_galleria import directive
from sphinx_galleria import collector
with open(os.path.join(
os.path.dirname(__file__),
'VERSION')) as version_file:
__version__ = version_file.read().strip()
__version_info__ = tuple(int(v) for v in __version__.split('.'))
import pkg_resources
__version__ = pkg_resources.get_distribution(__package__).version
__version_info__ = tuple(int(v) for v in __version__.split('.'))
def copy_images_files(app: Sphinx, env: BuildEnvironment) -> None: