Skip to content

Commit

Permalink
build(repo): configure semantic release
Browse files Browse the repository at this point in the history
fixes #108
  • Loading branch information
jwulf committed Apr 5, 2024
1 parent 9f23921 commit 435bbdb
Show file tree
Hide file tree
Showing 5 changed files with 74 additions and 6 deletions.
24 changes: 24 additions & 0 deletions .github/commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
module.exports = {
extends: ['@commitlint/config-conventional'],
rules: {
'type-enum': [
2,
'always',
[
'build',
'chore',
'ci',
'docs',
'feat',
'fix',
'perf',
'refactor',
'revert',
'style',
'test',
'minor',
'release'
]
]
}
};
20 changes: 19 additions & 1 deletion .releaserc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,25 @@
],
"repositoryUrl": "https://github.com/camunda/camunda-8-js-sdk.git",
"plugins": [
"@semantic-release/commit-analyzer",
[
"@semantic-release/commit-analyzer",
{
"releaseRules": [
{
"type": "feat",
"release": "patch"
},
{
"type": "release",
"release": "patch"
},
{
"type": "minor",
"release": "minor"
}
]
}
],
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
[
Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ To get started with contributing, please follow these steps:

## A note on commit messages

The repository uses []`semantic-release`](https://github.com/semantic-release/semantic-release) to create releases. Because we track the Camunda 8 Platform minor version, we need to treat feature implementation during a minor release cycle as a `fix` rather than a `feature`.
The repository uses []`semantic-release`](https://github.com/semantic-release/semantic-release) to create releases. Because we track the Camunda 8 Platform minor version, we treat feature implementation during a minor release cycle as a patch release rather than a minor release.

Creating a commit with a `feature` commit message will cause the package version minor release number to increment, which we only do when Camunda 8 Platform releases a new minor version.
Creating a commit with a `feat` commit message will cause the package version patch release number to increment. To update the minor version, a commit with the type `minor` is needed.

## Running tests

Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,18 @@

This is the official Camunda 8 JavaScript SDK. It is written in TypeScript and runs on Node.js. See details on why [this is not in a web browser](https://github.com/camunda/camunda-8-js-sdk/issues/79)).

# What does "supported" mean?
## What does "supported" mean?

This is the official supported-by-Camunda Nodejs SDK for Camunda Platform 8.

The Node.js SDK will not always support all features of Camunda Platform 8 immediately upon their release. Complete API coverage for a platform release will lag behind the platform release.

Prioritisation of implementing features is influenced by customer demand.

## Semantic versioning

The SDK package tracks Camunda Platform 8 minor versioning. Feature releases to support current Platform minor version features result in a patch release of the SDK.

## Using the SDK in your project

Install the SDK as a dependency:
Expand Down
26 changes: 24 additions & 2 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,25 @@
// eslint-disable-next-line no-undef
module.exports = {
extends: ['@commitlint/config-conventional'],
};
extends: ['@commitlint/config-conventional'],
rules: {
'type-enum': [
2,
'always',
[
'build',
'chore',
'ci',
'docs',
'feat',
'fix',
'perf',
'refactor',
'revert',
'style',
'test',
'release', // force a new patch release regardless of the commit message
'minor', // create a new minor release to match the Camunda Platform version
],
],
},
}

0 comments on commit 435bbdb

Please sign in to comment.