Skip to content

Commit 8e58f34

Browse files
author
Allen Winter
committed
Add documents for the developer
* branching * prerelease checklist * release checklist
1 parent 6d12597 commit 8e58f34

File tree

3 files changed

+190
-0
lines changed

3 files changed

+190
-0
lines changed

docs/developer/branching.md

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# Branching
2+
3+
Stable branches are branched from the "master" branch and called kdreports-X.Y,
4+
where 'X' the major version number and 'Y' is the minor version number.
5+
6+
We may refer to the "master" branch as the unstable branch.
7+
The currently actively kdreports-X.Y branch is known as the stable branch.
8+
9+
Bugfixes can stay in the current stable branch and do not require a new branch, which
10+
means that the following instructions can be skipped for patch-point releases.
11+
12+
## New minor version
13+
14+
For small feature modifications we need to create a new stable branch.
15+
If the current stable branch is kdreports-X.Y then the new branch will be called kdreports-X.Y+1.
16+
17+
For example, if the current stable branch is 2.1 then the new stable branch will be 2.2, like so:
18+
19+
```shell
20+
git checkout master
21+
git branch kdreports-2.2
22+
git checkout kdreports-2.2
23+
```
24+
25+
## New major version
26+
27+
However, for large feature modifications or API changes we need a major stable release.
28+
If the current stable branch is kdreports-X.Y then the new branch will be called kdreports-X+1.0.
29+
30+
For example, if the current stable branch is 2.1 then the new stable branch will be 3.0, like so:
31+
32+
```shell
33+
git checkout master
34+
git branch kdreports-3.0
35+
git checkout kdreports-3.0
36+
```
37+
38+
## After branching
39+
40+
Once the new branch is created we need to modify a few things.
41+
42+
### Source code changes
43+
44+
For a new major version:
45+
46+
* In the top-level `CMakeLists.txt` set `${PROJECT_NAME}_VERSION_MINOR` to 95
47+
* In the top-level `CMakeLists.txt` set `${PROJECT_NAME}_VERSION_PATCH` to 95
48+
* In the top-level `CMakeLists.txt` set `${PROJECT_NAME}_SOVERSION` to the new X.0
49+
* Add a new `docs/CHANGES_X_Y.txt` ("What's new in KDReports X.Y")
50+
51+
For a new minor version:
52+
53+
* In the top-level `CMakeLists.txt` set `${PROJECT_NAME}_VERSION_PATCH` to 95
54+
* In the a new `docs/CHANGES_X.Y.Z` ( ("What's new in KDReports X.Y.Z")
55+
56+
For any new branch, make sure to add entries for new branch name into the
57+
`.github/workflows/build.yml` file, inside the 'push' and 'pull_request" branch lists.
58+
59+
Make all the above changes and then git commit and push the new branch.
60+
61+
### And finally
62+
63+
* Update the KDABCI to the new stable branch (contact the KDAB CI team <buiildmaster@kdab.com>)
64+
* Update the Github Default Branch (see Default Branch setting at <https://github.com/KDAB/KDReports/settings>)
65+
* Initiate CI builds (both github and KDAB) of the new branch and make sure all is green before continuing.
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Pre-release source code review
2+
3+
See the bash script `deploy/release-kdreports.sh` in this project
4+
which automatically performs all these checks. Additionally,
5+
`deploy/release-kdreports.sh` does a build of the documentation
6+
plus creates and signs tar/zip balls. If all goes well, the user
7+
will be prompted to create the tag.
8+
9+
To use it run:
10+
11+
```shell
12+
./deploy/release-kdreports.sh X.Y.Z` # where X.Y.Z is the release version.
13+
```
14+
15+
Pre-release checklist:
16+
17+
* sync KDAB cmake files to upstream
18+
19+
compare the cmake/KDE files to their upstream versions in ssh://codereview.kdab.com:29418/kdab/extra-cmake-modules
20+
21+
* sync KDE cmake files to upstream
22+
23+
compare the cmake/ECM files to their upstream versions in <https://invent.kde.org/frameworks/extra-cmake-modules>
24+
25+
* ensures the Doxygen.cmake file is up-to-date for the doxygen version we use on KDABCI
26+
27+
```shell
28+
doxygen -u docs/api/Doxyfile.cmake
29+
```
30+
31+
* run a pre-commit check
32+
33+
```shell
34+
pre-commit run --all-files
35+
```
36+
37+
* verify ${PROJECT_NAME}_VERSION and ${PROJECT_NAME}_SOVERSION values in the top-level CMakeLists.txt
38+
39+
* Review docs/CHANGES_X_Y.txt for missing highlights or other information that needs to be added.
40+
41+
* `git commit` any changes made above and make sure the CIs are green before continuing.
42+
43+
Then create the new tag using the command:
44+
45+
```shell
46+
git tag -m "KDReports X.Y.Z" kdreports-X.Y.Z
47+
```
48+
49+
**DO NOT PUSH THE TAG YET!**

docs/developer/release-todo.md

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# Release Checklist
2+
3+
## Prerelease Source Checking
4+
5+
* look for any static checking issues (clazy, clang-tidy, cppcheck, etc) that may need fixing.
6+
* look for any changes in the README.md or INSTALL.txt that may need updating or improving.
7+
* follow the [prerelease source code review](prerelease-source.md) instructions.
8+
* merge any changes made during the review and make sure the CIs are green before continuing.
9+
* create the tag (**do not push the tag yet**)
10+
11+
## Prerelease Build Checking
12+
13+
Any last changes before pushing the tag? Any CI failures?
14+
15+
If so:
16+
17+
```shell
18+
git -d kdreports-X.Y.Z # delete the tag; good thing we didn't push it yet
19+
commit and push fixes
20+
update CHANGES_X_Z.txt as necessary
21+
./deploy/release-kdreports.sh X.Y.Z
22+
git tag -m "KDReports X.Y.Z" kdreports-X.Y.Z
23+
```
24+
25+
## Release
26+
27+
### Push the tag
28+
29+
```shell
30+
git push --tags
31+
```
32+
33+
### Create and push the release branch
34+
35+
In the subversion / commercial release days we did this. No idea if still needed. Doesn't hurt.
36+
37+
```shell
38+
# how things were done way back in the subversion and commercial release days
39+
git checkout -b kdreports-X.Y.Z-release && git push origin kdreports-X.Y.Z-release
40+
```
41+
42+
### Github
43+
44+
#### Make a release on Github
45+
46+
Go to <https://github.com/KDAB/KDReports/releases> and make an official release.
47+
48+
* push the "Draft a new release" button.
49+
* use the CHANGES_X_Y.txt to help write the release description.
50+
* hang the kdreports-X.Y.Z.tar.gz, kdreports-X.Y.Z.zip and kdreports-X.Y.0-doc.zip
51+
(for major and minor releases) on the github release page.
52+
* also hang the associated .asc files on the github release page.
53+
54+
#### Change the default branch
55+
56+
For major (X.Y.0) releases, change the default branch at
57+
<https://github.com/KDAB/KDReports/settings/branches> to kdreports-X.Y
58+
59+
## Postrelease
60+
61+
### Announcing
62+
63+
* update the
64+
[Products Release Schedule wiki](https://wiki.kdab.com/display/Products/Product+Release+Schedule)
65+
and [KDReports wiki](https://wiki.kdab.com/display/Products/KDReports)
66+
with new version numbers
67+
68+
* email the marketing team <marketing@kdab.com> and ask to have the news of
69+
the KDReports release posted to KDAB social media.
70+
71+
### Prepare for Next Release
72+
73+
In the branch:
74+
75+
* increase the ${PROJECT_NAME}_VERSION_PATCH value in the top-level CMakeLists.txt
76+
* merge to the "master" branch

0 commit comments

Comments
 (0)