@@ -462,7 +462,37 @@ and create the new release from the release branch (i.e. not from ``main``).
462
462
The release tag always starts with the letter ``v `` followed by the version
463
463
number, e.g. ``v2.1.0 ``.
464
464
465
- 6. Create and upload the PyPI package
465
+ 6. Mark the release in the main branch
466
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
467
+
468
+ When the (pre-)release is tagged, it is time to merge the release branch back into `main `.
469
+ We do this for two reasons, namely, one, to mark the point up to which commits in `main `
470
+ have been considered for inclusion into the present release, and, two, to inform
471
+ setuptools-scm about the version number so that it creates the correct version number in
472
+ `main `.
473
+ However, unlike in a normal merge, we do not want to integrate any of the changes from the
474
+ release branch into main.
475
+ This is because all changes that should be in both branches, i.e. bug fixes, originate from
476
+ `main ` anyway and the only other changes in the release branch relate to the release itself.
477
+ To take this into account, we perform the merge in this case on the command line using `the
478
+ ours merge strategy <https://git-scm.com/docs/merge-strategies#Documentation/merge-strategies.txt-ours-1> `__
479
+ (``git merge -s ours ``), not to be confused with the ``ours `` option to the ort merge strategy
480
+ (``git merge -X ours ``).
481
+ For details about merge strategies, see the above-linked page.
482
+ To execute the merge use following sequence of steps
483
+
484
+ .. code-block :: bash
485
+
486
+ git fetch
487
+ git checkout main
488
+ git pull
489
+ git merge -s ours v2.1.x
490
+ git push
491
+
492
+ Note that the release branch remains intact and you should continue any work on the release
493
+ on that branch.
494
+
495
+ 7. Create and upload the PyPI package
466
496
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
467
497
468
498
The package is automatically uploaded to the
@@ -493,7 +523,7 @@ Follow these steps to create a new Python package:
493
523
You can read more about this in
494
524
`Packaging Python Projects <https://packaging.python.org/tutorials/packaging-projects/ >`__.
495
525
496
- 7 . Create the Conda package
526
+ 8 . Create the Conda package
497
527
~~~~~~~~~~~~~~~~~~~~~~~~~~~
498
528
499
529
The ``esmvaltool `` package is published on the `conda-forge conda channel
@@ -514,7 +544,7 @@ they will merge the pull request, which will in turn publish the package on
514
544
conda-forge some time later.
515
545
Contact the feedstock maintainers if you want to become a maintainer yourself.
516
546
517
- 8 . Check the Docker images
547
+ 9 . Check the Docker images
518
548
~~~~~~~~~~~~~~~~~~~~~~~~~~
519
549
520
550
There are three main Docker container images available for ESMValTool on
0 commit comments