From 0442842af81379083a0b807915e0c8275c8de965 Mon Sep 17 00:00:00 2001 From: Henry Schreiner Date: Mon, 8 Apr 2024 15:20:30 -0400 Subject: [PATCH] docs: fix rtd and update release instructions Signed-off-by: Henry Schreiner --- .readthedocs.yaml | 2 +- docs/make_a_release.rst | 92 +++++++---------------------------------- 2 files changed, 15 insertions(+), 79 deletions(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 219a9bacb..57da64db2 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -13,4 +13,4 @@ build: python: install: - - requirements: docs/requirements-docs.txt + - requirements: docs/requirements.txt diff --git a/docs/make_a_release.rst b/docs/make_a_release.rst index d31de20f7..eb2ae3fbf 100644 --- a/docs/make_a_release.rst +++ b/docs/make_a_release.rst @@ -17,20 +17,6 @@ Prerequisites * You have a `GPG signing key `_. -------------------------- -Documentation conventions -------------------------- - -The commands reported below should be evaluated in the same terminal session. - -Commands to evaluate starts with a dollar sign. For example:: - - $ echo "Hello" - Hello - -means that ``echo "Hello"`` should be copied and evaluated in the terminal. - - --------------------- `PyPI`_: Step-by-step @@ -39,40 +25,27 @@ means that ``echo "Hello"`` should be copied and evaluated in the terminal. 1. Make sure that all CI tests are passing on `GitHub Actions`_. -2. Download the latest sources - - .. code:: +2. Download the latest sources if you don't already have them - $ cd /tmp && \ - git clone git@github.com:scikit-build/cmake-python-distributions cmake-python-distributions-release && \ - cd cmake-python-distributions-release + .. code:: console + $ git clone git@github.com:scikit-build/cmake-python-distributions + $ cd cmake-python-distributions -3. List all tags sorted by version - .. code:: +3. Ask nox for the instructions on what to type - $ git fetch --tags && \ - git tag -l | sort -V + .. code:: console + $ nox -s tag_release -4. Choose the next release version number - .. code:: +4. Run the suggested lines, probably something like this: - $ release=X.Y.Z + .. code:: console - .. warning:: - - To ensure the packages are uploaded on `PyPI`_, tags must match this regular - expression: ``^[0-9]+(\.[0-9]+)*(\.post[0-9]+)?$``. - - -5. Tag the release - - .. code:: - - $ git tag --sign -m "cmake-python-distributions $release" $release main + $ git tag --sign -m 'cmake-python-distributions 3.29.1' 3.29.1 main + $ git push origin 3.29.1 .. warning:: @@ -80,51 +53,14 @@ means that ``echo "Hello"`` should be copied and evaluated in the terminal. to sign the tag. -6. Publish the release tag - - .. code:: +5. Check the status of the builds on `GitHub Actions`_. - $ git push origin $release +6. Once the builds are completed, check that the distributions are available on `PyPI`_. - .. note:: This will trigger builds on each CI services and automatically upload the wheels \ - and source distribution on `PyPI`_. - -7. Check the status of the builds on `GitHub Actions`_. - -8. Once the builds are completed, check that the distributions are available on `PyPI`_. - -9. Make a GitHub release based on the tag. This will display the latest version +7. Make a GitHub release based on the tag. This will display the latest version in the GitHub sidebar, and will notify release watchers of the release. Title it `Version X.Y.Z` and add a little note about what changed (Python only). -10. Create a clean testing environment to test the installation - - .. code:: - - $ pushd $(mktemp -d) && \ - mkvirtualenv cmake-$release-install-test && \ - pip install cmake && \ - cmake --version - - .. note:: - - If the ``mkvirtualenv`` command is not available, this means you do not have `virtualenvwrapper`_ - installed, in that case, you could either install it or directly use `virtualenv`_ or `venv`_. - -11. Cleanup - - .. code:: - - $ popd && \ - deactivate && \ - rm -rf dist/* && \ - rmvirtualenv cmake-$release-install-test - - -.. _virtualenvwrapper: https://virtualenvwrapper.readthedocs.io/ -.. _virtualenv: https://virtualenv.pypa.io/en/latest -.. _venv: https://docs.python.org/3/library/venv.html - .. _GitHub Actions: https://github.com/scikit-build/cmake-python-distributions/actions/workflows/build.yml