From dedeff88ce2b41a1a0df001f3220c89493b1d53d Mon Sep 17 00:00:00 2001 From: Alex Root Junior Date: Mon, 7 Nov 2022 06:35:55 +0200 Subject: [PATCH] Added sphinxcontrib-towncrier integration --- CHANGES.rst | 2 ++ CHANGES/1017.doc.rst | 2 +- docs/conf.py | 7 ++++++- poetry.lock | 18 +++++++++++++++++- pyproject.toml | 1 + requirements/docs.txt | 1 + 6 files changed, 28 insertions(+), 3 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 1b7e4377..e7310063 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -12,6 +12,8 @@ Changelog WARNING: Don't drop the next directive! +.. towncrier-draft-entries:: |release| [UNRELEASED DRAFT] + .. towncrier release notes start 3.0.0b5 (2022-10-02) diff --git a/CHANGES/1017.doc.rst b/CHANGES/1017.doc.rst index 50ab706e..104d382c 100644 --- a/CHANGES/1017.doc.rst +++ b/CHANGES/1017.doc.rst @@ -1 +1 @@ -Fix UA translations in index.po +Fixed UA translations in index.po diff --git a/docs/conf.py b/docs/conf.py index 42bf33ec..c8d4c4ec 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -19,7 +19,7 @@ html_theme_options = {} html_css_files = [ "stylesheets/extra.css", ] -highlight_language = 'python3' +highlight_language = "python3" extensions = [ "sphinx.ext.todo", @@ -30,6 +30,7 @@ extensions = [ "sphinx-prompt", "sphinx_substitution_extensions", "sphinx_copybutton", + "sphinxcontrib.towncrier.ext", ] rst_prolog = f""" @@ -64,3 +65,7 @@ texinfo_documents = [ ] # add_module_names = False + +towncrier_draft_autoversion_mode = 'draft' +towncrier_draft_include_empty = True +# towncrier_draft_working_directory = PROJECT_ROOT_DIR diff --git a/poetry.lock b/poetry.lock index 87c98e40..77c9de5a 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1060,6 +1060,18 @@ python-versions = ">=3.5" lint = ["docutils-stubs", "flake8", "mypy"] test = ["pytest"] +[[package]] +name = "sphinxcontrib-towncrier" +version = "0.3.1a3" +description = "An RST directive for injecting a Towncrier-generated changelog draft containing fragments for the unreleased (next) project version" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +sphinx = "*" +towncrier = ">=19.2" + [[package]] name = "toml" version = "0.10.2" @@ -1195,7 +1207,7 @@ redis = ["redis"] [metadata] lock-version = "1.1" python-versions = "^3.8" -content-hash = "96a502ce3830054d2b1f248f21b710d172b9c5c3bf8943e19f7478a0586dfcf5" +content-hash = "0845f5cc5f08f26d2780e6696fe66d84aab76cf5f720b742839f34552377a9fa" [metadata.files] aiofiles = [ @@ -1940,6 +1952,10 @@ sphinxcontrib-serializinghtml = [ {file = "sphinxcontrib-serializinghtml-1.1.5.tar.gz", hash = "sha256:aa5f6de5dfdf809ef505c4895e51ef5c9eac17d0f287933eb49ec495280b6952"}, {file = "sphinxcontrib_serializinghtml-1.1.5-py2.py3-none-any.whl", hash = "sha256:352a9a00ae864471d3a7ead8d7d79f5fc0b57e8b3f95e9867eb9eb28999b92fd"}, ] +sphinxcontrib-towncrier = [ + {file = "sphinxcontrib-towncrier-0.3.1a3.tar.gz", hash = "sha256:7d521a435c06b39d519ce0c9c1495a9e5f0e7db7fd243674ee4a16ac1ce1812e"}, + {file = "sphinxcontrib_towncrier-0.3.1a3-py3-none-any.whl", hash = "sha256:eedf44b0e31f0bc7cc1dc0f608f9e84fb8a7aa775f5b3c89ce17bca062f12048"}, +] toml = [ {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, diff --git a/pyproject.toml b/pyproject.toml index 9d0bb66b..1b4ee3ac 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,6 +73,7 @@ pygments = "^2.4" pymdown-extensions = "^9.6" markdown-include = "^0.7.0" Pygments = "^2.13.0" +sphinxcontrib-towncrier = "^0.3.1a3" [tool.poetry.group.test.dependencies] diff --git a/requirements/docs.txt b/requirements/docs.txt index 6cf96861..2f7d49ae 100644 --- a/requirements/docs.txt +++ b/requirements/docs.txt @@ -53,6 +53,7 @@ sphinxcontrib-htmlhelp==2.0.0 ; python_version >= "3.8" and python_version < "4. sphinxcontrib-jsmath==1.0.1 ; python_version >= "3.8" and python_version < "4.0" sphinxcontrib-qthelp==1.0.3 ; python_version >= "3.8" and python_version < "4.0" sphinxcontrib-serializinghtml==1.1.5 ; python_version >= "3.8" and python_version < "4.0" +sphinxcontrib-towncrier==0.3.1a3 ; python_version >= "3.8" and python_version < "4.0" tomli==2.0.1 ; python_version >= "3.8" and python_version < "4.0" tornado==6.2 ; python_version >= "3.8" and python_version < "4.0" towncrier==22.8.0 ; python_version >= "3.8" and python_version < "4.0"