To create a release of the software we are using the release functionality of GitHub. Under the tab code
there is a section
Releases
(Right side). When selected all current releases will be displayed, and a new release can be created (draft release).
The standard branch to create a release from should be the main
branch.
Enter the following values when creating a new release:
0.1.4
.
Also press Create new tag
to create the new label.main
.Release <tag> of <project name>
, for instance
Release 0.1.4 of SCL Auto Alignment Service
Auto-generate release notes
to generate these.
Check Configure release notes generation to configure how these are generated.Now press Publish release
to create the release. For every repository that creates a software product (artifacts or docker images)
a GitHub Action (release-project.yml
) is defined. This action runs when a release is created.
on:
release:
types: [released]
Depending on the type of project different steps will be executed. Common steps are:
Depending on the type of project other steps will be executed. Some examples are:
To publish artifacts to GiHub Packages a distribution section needs to be added to pom.xml of the root.
<distributionManagement>
<repository>
<id>github-packages-compas</id>
<name>GitHub Packages</name>
<url>https://maven.pkg.github.com/com-pas/[repo-name]</url>
</repository>
</distributionManagement>
The ID is the same as the ID used for the repository section in Maven Build.
This way the same credentials will be used to connect to GitHub Packages as described Maven Build.
Replace [repo-name]
with the name of the repository from CoMPAS.
During creating of a release we will use the GitHub feature to automatically generate the release notes using the pull requests.
The way these release notes are created can be configured by adding/updating the file release.yml
to the directory .github
.
The content of the file release.yml
is currently:
changelog:
exclude:
labels:
- wontfix
- duplicate
- invalid
categories:
- title: New Features
labels:
- enhancement
- title: Bugfixes
labels:
- bug
- title: Tooling changes
labels:
- tooling
- title: Dependency updates
labels:
- dependencies
- title: Other Changes
labels:
- "*"
This will group different pull request using the different labels.