🚀 Releasing a New Version
This is a step-by-step guide for making a new HestiaStore release.
☝️ Versioning of the project
The project uses the traditional versioning pattern known as Semantic Versioning, detailed at https://semver.org. The version number consists of three components separated by dots:
Each number has the following meaning:
0
- Major project version. Project API could be incompatible between two major versions.3
- Minor project version. Contains changes in features, performance optimizations, and small improvements. Minor versions should be compatible.6
- Patch version. Bug fixing project release.
There are also snapshot versions with version number 0.3.6-SNAPSHOT
. Snapshot versions should not be stored in the Maven repository.
🕊️ Branching strategy
We use a simplified GitHub Flow:
main
: the primary development and release branch. Small changes may be committed directly tomain
, while larger or experimental features must be developed in a separate branch and merged via pull request.- Feature branches are created from
main
for larger or isolated changes. Use descriptive names likefeature/compression
,fix/index-scan
, etc.
The deprecated devel
branch has been removed and is no longer used.
🧑💻 Release prerequisites
The release will be published to Maven Central. Release configuration secrets are placed at the Maven settings file ~/.m2/settings.xml
.
Adjust settings.xml
in ~/.m2/settings.xml
as described in GitHub's official documentation on how to work with the GitHub Maven repository. Generate a valid token and you are done.
Provide correct package signature
In your ~/.m2/settings.xml
file, add the following section:
<settings>
...
<profile>
<id>release</id>
<properties>
<gpg.executable>gpg</gpg.executable>
<gpg.passphrase>--pgp-password--</gpg.passphrase>
</properties>
</profile>
...
</settings>
Setup maven central accout secrets
This provides org.sonatype.central:central-publishing-maven-plugin
plugin secrets to enable login to the Maven Central account where release data will be placed.
You must have an account with a verified namespace org.hestiastore
at central.sonatype.com. From the Account
section, generate a key and password. These should be added to:
<settings>
...
<servers>
<server>
<id>central</id>
<username>------</username>
<password>---------------token---------------</password>
</server>
</servers>
...
</settings>
Perform release
Perform the following steps to create a new release:
1. 🏷️ Checkout the main
branch
2. 🔢 Set the Release Version
3. 🏷️ Tag and Push the Release
4. 🚀 Deploy the Release
Deploy the release (can be later automated via GitHub Actions or done manually):
5. 📈 Bump to the Next Snapshot Version
mvn versions:set -DnewVersion=0.0.13-SNAPSHOT
git commit -am "post-release: bumped to 0.0.13-SNAPSHOT"
git push
6. 📝 Publish the Release on GitHub
- Go to https://github.com/jajir/HestiaStore/releases and choose
Draft a new release
. - From the drop-down box
target: main
, selectrecent commits
and select the correct one with namerelease: version 0.0.12
. - From the drop-down box
Choose a tag
enterrelease-0.0.12
and clickCreate new tag: release ...
. Now in the repo, the tag clearly signals the new release. - Release title should be
Release 0.0.3
and in theWrite
field, use the text generated from the template below: - Press
Publish release
.
Text template:
Release to maven central:
```xml
<dependencies>
<dependency>
<groupId>org.hestiastore.index</groupId>
<artifactId>core</artifactId>
<version>0.0.3</version> <!-- Replace with the actual version -->
</dependency>
</dependencies>
```
7. 🎉 Celebrate
That's it — the release is live and development can continue.
🧰 Helpful Commands
At the beginning there may be problems. Here are a few tricks that help to gather more information.
How to Use a Custom settings.xml File
How to Set the Maven Project Version
Check dependencies
Try to update dependencies. Check them with: