Build automation tool
Keyple uses Gradle.
Versioning rules
Keyple components are versioned according to Semantic Versioning 2.0.0 which is based on the three numbers X.Y.Z
-api
), the incrementation of Z
indicates only a documentation update.Continuous integration
Keyple continuous integration is based on GitHub Actions and uses the reusable workflows defined in the dedicated Keyple Actions repository.
The CI automates the following tasks:
- verify the validity of the version;
- verify the code formatting using spotless;
- build the code;
- execute unit tests;
- sign and publish artifacts to Maven Central Repository;
- publish the API documentation to the unified Keyple’s documentation GitHub pages;
- publish the code quality report to SonarCloud.
Snapshot publication
A new snapshot version (suffixed with -SNAPSHOT
) is automatically built and published each time a commit is pushed
to the main
branch.
This allows developers to use the latest development state of Keyple without waiting for an official release. The published SNAPSHOT artifacts are available from the Eclipse Maven Snapshots repository.
gradle.properties
must contain the -SNAPSHOT
suffix.Release publication
A new release version is automatically built and published whenever a GitHub release is created.
The generated artifact is based on the commit referenced by the newly created tag, ensuring full traceability between the source code and the published artifacts.
The GitHub release tag name must strictly match the version declared in the gradle.properties
file (without the
-SNAPSHOT
suffix).
For example, if the component version in gradle.properties
is 2.5.0-SNAPSHOT
, the GitHub release tag must be
2.5.0
.
Integration tests
Integration tests are defined in an independent GitHub repository: keyple-integration-java-test
Release procedure
- Create a branch dedicated to the current release.
- Check
gradle.properties
file:- Check the consistency of the version (do not remove
-SNAPSHOT
suffix).
- Check the consistency of the version (do not remove
- Check
build.gradle.kts
file:- Use only released dependencies.
- Upgrade Keyple dependencies to their latest released versions.
- Update
CHANGELOG.md
file:- Verify the consistency of the
Unreleased
section. - Move content of
Unreleased
section to a new “release” section. - Update bottom links.
- Verify the consistency of the
- Build and test the component locally.
- Commit the modified files.
- Push and create a pull request to merge the branch into
main
. - Await the success of the build by the CI on source branch.
- Squash and merge the pull request.
- Await the success of the snapshot publication by the CI on
main
branch. - Create a release on GitHub:
- Set tag
x.y.z
- Set release name
x.y.z
- Set the content by copying/pasting the content of the current release description in the
CHANGELOG.md
file without the bottom links.
- Set tag
- Await the success of the release publication by the CI on
main
branch. - Check the availability of the release on the Maven Repository. This step may take from 10 minutes to 2 hours.
- Update this website:
- Update version in
params.yaml
file. - Update table content of
dependency-check.md
file. - Update others elements if needed (user guides, developer guides, etc…).
- Commit and push the modifications.
- Update version in