Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/developer_guide/developer_guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@
:maxdepth: 2

../design
development
plugins
modules/modules
../user_guide/how_to_release
77 changes: 0 additions & 77 deletions doc/developer_guide/development.rst

This file was deleted.

85 changes: 76 additions & 9 deletions doc/user_guide/how_to_release.rst
Original file line number Diff line number Diff line change
@@ -1,12 +1,79 @@
How to Release?
===============

#. Use :code:`nox -s release:prepare` to prepare the project for a new release.
#. Merge your **Pull Request** to the **default branch**
#. Use :code:`git remote show origin | sed -n '/HEAD branch/s/.*: //p'` to output the **default branch**
#. Use :code:`git checkout <default branch>` Switch to the **default branch**
#. Use :code:`git pull` to update branch
#. Use :code:`TAG=<name>` to set a variable named **"TAG"**
#. Use :code:`git tag "${TAG}"` to create a new tag in your repo
#. Use :code:`git push origin "${TAG}"` to push it to remote
#. GitHub workflow **CD** reacts on this tag and starts the release process
Creating a Release
++++++++++++++++++

1. Set a variable named **TAG** with the appropriate version numbers:

.. code-block:: shell

TAG="<major>.<minor>.<patch>"

#. Prepare the project for a new release:

.. code-block:: shell

nox -s release:prepare -- "${TAG}"

#. Merge your **Pull Request** to the **default branch**
#. Switch to the **default branch**:

.. code-block:: shell

git checkout $(git remote show origin | sed -n '/HEAD branch/s/.*: //p')

#. Update branch:

.. code-block:: shell

git pull

#. Create a new tag in your local repo:

.. code-block:: shell

git tag "${TAG}"

#. Push the repo to remote:

.. code-block:: shell

git push origin "${TAG}"

.. hint::

GitHub workflow **.github/workflows/cd.yml** reacts on this tag and starts the release process

What to do if the release failed?
+++++++++++++++++++++++++++++++++

The release failed during pre-release checks
--------------------------------------------

#. Delete the local tag

.. code-block:: shell

git tag -d "${TAG}"

#. Delete the remote tag

.. code-block:: shell

git push --delete origin "${TAG}"

#. Fix the issue(s) which lead to the failing checks
#. Start the release process from the beginning


One of the release steps failed (Partial Release)
-------------------------------------------------
#. Check the Github action/workflow to see which steps failed
#. Finish or redo the failed release steps manually

.. note:: Example

**Scenario**: Publishing of the release on Github was successfully but during the PyPi release, the upload step got interrupted.

**Solution**: Manually push the package to PyPi