1
|
1
|
new file mode 100644
|
...
|
...
|
@@ -0,0 +1,155 @@
|
|
1
|
+Making a Kwant release
|
|
2
|
+======================
|
|
3
|
+This document guides a contributor through creating a release of Kwant.
|
|
4
|
+
|
|
5
|
+Preflight checks
|
|
6
|
+################
|
|
7
|
+The following checks should be made *before* tagging the release.
|
|
8
|
+
|
|
9
|
+Check that all issues are resolved
|
|
10
|
+----------------------------------
|
|
11
|
+Check that all the issues and merge requests for the appropriate
|
|
12
|
+`milestone <https://gitlab.kwant-project.org/kwant/kwant/milestones>`
|
|
13
|
+have been resolved. Any unresolved issues should have their milestone
|
|
14
|
+bumped.
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+Ensure that all tests pass
|
|
18
|
+--------------------------
|
|
19
|
+This should be as simple as verifying that the latest CI pipeline succeeded.
|
|
20
|
+For major and minor releases we will be tagging the ``master`` branch.
|
|
21
|
+For patch releases, the ``stable`` branch.
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+Inspect the documentation
|
|
25
|
+-------------------------
|
|
26
|
+If the CI pipeline succeeded, then the latest docs should be available at:
|
|
27
|
+
|
|
28
|
+ https://test.kwant-project.org/doc/<branch name>
|
|
29
|
+
|
|
30
|
+Check that there are no glaring deficiencies.
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+Update the ``whatsnew`` file
|
|
34
|
+----------------------------
|
|
35
|
+Check that there is an appropriate ``whatsnew`` file in ``doc/source/pre/whatsnew``.
|
|
36
|
+This should be named as::
|
|
37
|
+
|
|
38
|
+ <major>.<minor>.<patch>.rst
|
|
39
|
+
|
|
40
|
+and should contain a list of the user-facing changes that were made in the
|
|
41
|
+release. With any luck this file will have been updated after any major
|
|
42
|
+features were released, if not then you can see what commits were introduced
|
|
43
|
+since the last release using ``git log``. You can also see what issues were
|
|
44
|
+assigned to the release's milestons and get an idea of what was introduced
|
|
45
|
+from there.
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+Tag the release
|
|
49
|
+###############
|
|
50
|
+Make an *annotated*, *signed* tag for the release. The tag must have the semantic
|
|
51
|
+versioning format::
|
|
52
|
+
|
|
53
|
+ v<major>.<minor>.<patch>
|
|
54
|
+
|
|
55
|
+Once the tag has been created, push it to Kwant Gitlab.
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+Post-tagging
|
|
59
|
+############
|
|
60
|
+Pushing a new tag to Kwant Gitlab will kick off a few CI jobs, but there is
|
|
61
|
+still some manual work to do.
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+Prepare the Debian package
|
|
65
|
+--------------------------
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+Gather the autobuilt packages from CI
|
|
69
|
+-------------------------------------
|
|
70
|
+CI automatically generates:
|
|
71
|
+
|
|
72
|
++ HTML documentation
|
|
73
|
++ Zipped HTML documentation
|
|
74
|
++ PDF documentation
|
|
75
|
++ ``sdist`` package (for upload to PyPI)
|
|
76
|
+
|
|
77
|
+These can be found in the artifacts of the last CI job in the pipeline,
|
|
78
|
+``gather release artifacts``.
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+Publish to the Kwant website
|
|
82
|
+----------------------------
|
|
83
|
+To do the following you will need access to the webroots of ``downloads.kwant-project.org``
|
|
84
|
+and ``kwant-project.org``. Ask Christoph Groth if you need to be granted access.
|
|
85
|
+
|
|
86
|
+Take the tar archive in the ``dist`` directory of the CI artifacts and generate
|
|
87
|
+a detached GPG signature::
|
|
88
|
+
|
|
89
|
+ gpg --armor --detach-sign kwant-<major>.<minor>.<patch>.tar.gz
|
|
90
|
+
|
|
91
|
+Take the archive and the ``.asc`` signature file that was just generated
|
|
92
|
+and upload them to the ``kwant`` directory of ``downloads.kwant-project.org``.
|
|
93
|
+
|
|
94
|
+Take the zip archive and the PDF in the ``docs`` directory of the CI artifacts
|
|
95
|
+and upload them to the ``doc`` directory of ``downloads.kwant-project.org``.
|
|
96
|
+Point the symbolic links ``latest.zip`` and ``latest.pdf`` to these new files.
|
|
97
|
+
|
|
98
|
+Take the ``docs/html`` directory of the CI artifacts and upload them to::
|
|
99
|
+
|
|
100
|
+ doc/<major>.<minor>.<patch>/
|
|
101
|
+
|
|
102
|
+on ``kwant-project.org``. Point the symbolic link ``<major>`` to this directory.
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+Publish to PyPI
|
|
106
|
+---------------
|
|
107
|
+Install `twine <https://pypi.python.org/pypi/twine>` and use it to upload
|
|
108
|
+the tar archive in the ``sdist`` directory of the Ci artifacts downloaded
|
|
109
|
+in the previous step::
|
|
110
|
+
|
|
111
|
+ twine upload --sign -u <PyPI username> -p <PyPI password> sdist/*
|
|
112
|
+
|
|
113
|
+the ``--sign`` flag signs the uploaded package with your default GPG key.
|
|
114
|
+Ask Christoph Groth for the Kwant PyPI credentials.
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+Publish to Launchpad
|
|
118
|
+--------------------
|
|
119
|
+
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+Publish to Conda forge
|
|
123
|
+----------------------
|
|
124
|
+Conda forge automates build/deploy by using CI on Github repositoried containing
|
|
125
|
+recipes for making packages from their source distributions.
|
|
126
|
+
|
|
127
|
+Fork the `Kwant feedstock <https://github.com/conda-forge/kwant-feedstock>`
|
|
128
|
+repository and edit the file ``recipe/meta.yml``. Correctly set the ``version``
|
|
129
|
+at the top of the file. Set the ``sha256`` string in the ``source`` section
|
|
130
|
+near the top of the file to the SHA256 hash of the kwant source distribution
|
|
131
|
+that was uploaded to ``downloads.kwant-project.org``. This can be found by::
|
|
132
|
+
|
|
133
|
+ sha256sum kwant-<major>.<minor>.<patch>.tar.gz
|
|
134
|
+
|
|
135
|
+Now commit these changes and open a pull request on the Kwant feedstock
|
|
136
|
+repository that includes your change. Ask Bas Nijholt or Joseph Weston
|
|
137
|
+to review and accept the pull request, so that Kwant will be rebuilt.
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+Announce the release
|
|
141
|
+--------------------
|
|
142
|
+Write a short post summarizing the highlights of the release on the
|
|
143
|
+`Kwant website <https://gitlab.kwant-project.org/kwant/website>`, then
|
|
144
|
+post this to the mailing list kwant-discuss@kwant-project.org.
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+Working towards the next release
|
|
148
|
+################################
|
|
149
|
+After finalizing a release, a new ``whatsnew`` file should be created for
|
|
150
|
+the *next* release, and this addition should be committed and tagged as::
|
|
151
|
+
|
|
152
|
+ <new major>.<new minor>.<new patch>a0
|
|
153
|
+
|
|
154
|
+This tag should be pushed to Kwant Gitlab, and a new milestone for the next
|
|
155
|
+release should be created.
|