Skip to content

Commit 91f9b08

Browse files
authored
[chore]: prepare the changelog for next version (#2921)
* prepare the changelog * add backup incompatibility to breaking changes * prepare the version as a 7 instead of 6.1 * allow to define prerelease version in workflow - and fix that prerelease version number was not increased * fix changelog
1 parent a4051ad commit 91f9b08

File tree

6 files changed

+46
-19
lines changed

6 files changed

+46
-19
lines changed

.github/workflows/nightly-dev-release.yml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ on:
44
schedule:
55
- cron: 0 2 * * * # Every day at 02:00
66
workflow_dispatch: # Manually on demand
7+
inputs:
8+
versionBump:
9+
description: 'Type of version bump'
10+
required: true
11+
default: 'prerelease'
12+
type: choice
13+
options:
14+
- prerelease
15+
- prepatch
16+
- preminor
17+
- premajor
718

819
jobs:
920
publish-config:
@@ -65,6 +76,8 @@ jobs:
6576

6677
- name: Determine the version bump
6778
if: steps.changes.outputs.result == 'ok'
79+
env:
80+
VERSION_BUMP: ${{ inputs.versionBump }}
6881
id: version
6982
uses: actions/github-script@v7
7083
with:
@@ -94,12 +107,13 @@ jobs:
94107
}
95108
96109
// Figure out the next version
97-
const nightlyVersion = `${semver.inc(parsed, "prerelease", prereleaseIdentifier)}-${dateStr}-${sha}`;
110+
const versionBump = process.env.VERSION_BUMP || 'prerelease';
111+
const nightlyVersion = `${parsed.inc(process.env.VERSION_BUMP, prereleaseIdentifier)}-${dateStr}-${sha}`;
98112
99113
// ensure that io-pack is in sync
100114
const fs = require('fs');
101115
const ioPack = JSON.parse(fs.readFileSync(`${process.env.GITHUB_WORKSPACE}/packages/controller/io-package.json`));
102-
ioPack.common.version = semver.inc(nightlyVersion, 'patch');;
116+
ioPack.common.version = semver.inc(nightlyVersion, 'patch');
103117
fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/packages/controller/io-package.json`, JSON.stringify(ioPack, null, 2));
104118
105119
return nightlyVersion;

CHANGELOG.md

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,30 @@
33
Placeholder for the next version (at the beginning of the line):
44
## **WORK IN PROGRESS**
55
-->
6-
## **WORK IN PROGRESS**
7-
* (bluefox) Added support for dynamic notification layout (in Admin)
8-
* (@foxriver76) updated plugin base and sentry plugin to version 2
9-
* (@foxriver76) enhanced translations for the `diskSpaceIssues` notification category
6+
## **WORK IN PROGRESS** - Lucy
7+
**Breaking changes**
8+
* Backups created with 7.0.x cannot be restored with previous version
9+
10+
**Features**
11+
* (@GermanBluefox) Added support for dynamic notification data
12+
(with this feature developers can create interactive notifications in the Admin adapter)
13+
* (@GermanBluefox/@foxriver76) implemented automatic upload on adapter start if version mismatch is detected
14+
* (@foxriver76) improved backup/restore process to work for arbitrary large installations
1015
* (@foxriver76) added notification if new image is available on Docker Hub (for official docker systems)
16+
17+
**Optimizations and fixes**
1118
* (@foxriver76) extend the time to wait until controller is stopped on controller UI upgrade
12-
* (@foxriver76) improved backup/restore process to work for arbitrary large installations
13-
* (@GermanBluefox/@foxriver76) implemented automatic upload on adapter start if version mismatch is detected
19+
* (@foxriver76) enhanced translations for the `diskSpaceIssues` notification category
1420
* (@foxriver76) enriched logging on upload with version information
1521

22+
**Developer relevant new features**
23+
* (@GermanBluefox) On `registerNotification` developers can now pass additional context data
24+
e.g. for dynamic notifications with Admin adapter
25+
26+
**Developer relevant Optimizations and Fixes**
27+
* (@foxriver76) updated plugin base and sentry plugin to version 2
28+
* (@GermanBluefox/@foxriver76) multiple improvements on type level
29+
1630
## 6.0.11 (2024-08-21) - Kiera
1731
* (foxriver76) only generate `packageUpdates` notification, if new updates detected
1832

@@ -171,7 +185,7 @@
171185
* (foxriver76) new `io-package` flag `common.supportedMessages` to replace `messagebox` and other messagebox-related properties
172186
* (foxriver76) `adapter.sendTo` now accepts an optional `timeout` argument
173187

174-
* **Developer relevant Optimizations and Fixes**
188+
**Developer relevant Optimizations and Fixes**
175189
* (foxriver76) Ensure setObjectNotExists returns id on success
176190
* (foxriver76) Fix Typings for sendTo/sendToHost
177191
* (Bluefox) Add User permission check to requireLog

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -512,7 +512,7 @@ This method takes the following parameters:
512512
* scope: scope to be addressed
513513
* category: category to be addressed, if a null message will be checked by regex of given scope
514514
* message: message to be stored/checked
515-
* options: Available with js-controller version 6.1. Additional options for the notification, currently you can provide additional `contextData` which is also stored with the notification information. Notification processing adapters can use this data
515+
* options: Available with js-controller version 7.0. Additional options for the notification, currently you can provide additional `contextData` which is also stored with the notification information. Notification processing adapters can use this data
516516

517517
Note, that the structure of the `contextData` which can be stored via the options object is not defined by the controller. Adapters which handle messages can use individual data attributes.
518518
Currently, it is planned to support individual notification customization in the `admin` adapter. More information will be available in the `admin` adapter as soon as this feature is ready.
@@ -1309,7 +1309,7 @@ Feature status: **stable**
13091309

13101310
There are several environment variables which are respected by the js-controller.
13111311

1312-
#### `IOB_NO_SETCAP` (up from js-controller 6.1.X)
1312+
#### `IOB_NO_SETCAP` (up from js-controller 7.0.X)
13131313
By default, the js-controller sets some capabilities on the Node.js executable.
13141314
Currently, `cap_net_admin`, `cap_net_bind_service`, `cap_net_raw` are set to e.g. allow Node.js to start/stop BLE advertising without root privileges. On installation these are set by the ioBroker installer.
13151315
However, on upgrades of Node.js these get lost. If js-controller detects a Node.js upgrade, it will ensure that these capabilities are set again.

packages/adapter/src/lib/adapter/adapter.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5140,7 +5140,7 @@ export class AdapterClass extends EventEmitter {
51405140
*/
51415141
createDevice(deviceName: unknown, common: unknown, _native?: unknown, options?: unknown, callback?: unknown): any {
51425142
this._logger.info(
5143-
`${this.namespaceLog} Method "createDevice" is deprecated and will be removed in js-controller 7, use "extendObject/setObjectNotExists" instead`,
5143+
`${this.namespaceLog} Method "createDevice" is deprecated and will be removed in js-controller 7.1, use "extendObject/setObjectNotExists" instead`,
51445144
);
51455145

51465146
if (typeof options === 'function') {
@@ -5243,7 +5243,7 @@ export class AdapterClass extends EventEmitter {
52435243
callback?: unknown,
52445244
): any {
52455245
this._logger.info(
5246-
`${this.namespaceLog} Method "createChannel" is deprecated and will be removed in js-controller 7, use "extendObject/setObjectNotExists" instead`,
5246+
`${this.namespaceLog} Method "createChannel" is deprecated and will be removed in js-controller 7.1, use "extendObject/setObjectNotExists" instead`,
52475247
);
52485248

52495249
if (typeof options === 'function') {
@@ -5354,7 +5354,7 @@ export class AdapterClass extends EventEmitter {
53545354
callback?: unknown,
53555355
): any {
53565356
this._logger.info(
5357-
`${this.namespaceLog} Method "createState" is deprecated and will be removed in js-controller 7, use "extendObject/setObjectNotExists" instead`,
5357+
`${this.namespaceLog} Method "createState" is deprecated and will be removed in js-controller 7.1, use "extendObject/setObjectNotExists" instead`,
53585358
);
53595359

53605360
if (typeof options === 'function') {
@@ -5543,7 +5543,7 @@ export class AdapterClass extends EventEmitter {
55435543
*/
55445544
deleteDevice(deviceName: unknown, options: unknown, callback?: unknown): any {
55455545
this._logger.info(
5546-
`${this.namespaceLog} Method "deleteDevice" is deprecated and will be removed in js-controller 7, use "delObject" instead`,
5546+
`${this.namespaceLog} Method "deleteDevice" is deprecated and will be removed in js-controller 7.1, use "delObject" instead`,
55475547
);
55485548

55495549
if (typeof options === 'function') {
@@ -5873,7 +5873,7 @@ export class AdapterClass extends EventEmitter {
58735873
*/
58745874
deleteChannel(parentDevice: unknown, channelName: unknown, options?: unknown, callback?: unknown): any {
58755875
this._logger.info(
5876-
`${this.namespaceLog} Method "deleteChannel" is deprecated and will be removed in js-controller 7, use "delObject" instead`,
5876+
`${this.namespaceLog} Method "deleteChannel" is deprecated and will be removed in js-controller 7.1, use "delObject" instead`,
58775877
);
58785878

58795879
if (typeof options === 'function') {
@@ -5989,7 +5989,7 @@ export class AdapterClass extends EventEmitter {
59895989
callback?: unknown,
59905990
): any {
59915991
this._logger.info(
5992-
`${this.namespaceLog} Method "deleteState" is deprecated and will be removed in js-controller 7, use "delObject" instead`,
5992+
`${this.namespaceLog} Method "deleteState" is deprecated and will be removed in js-controller 7.1, use "delObject" instead`,
59935993
);
59945994

59955995
if (typeof parentChannel === 'function' && stateName === undefined) {

packages/adapter/src/lib/adapter/constants.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ const SUPPORTED_FEATURES_INTERNAL = [
6363
'CONTROLLER_LICENSE_MANAGER', // Controller can read licenses from iobroker.net. Since js-controller 4.0
6464
'CONTROLLER_OS_PACKAGE_UPGRADE', // Controller can upgrade OS packages
6565
'DEL_INSTANCE_CUSTOM', // instances/adapter can be deleted with --custom flag to remove corresponding custom of all objects. Since js-controller 4.0
66-
'BINARY_STATE_EVENT', // stateChange event could be received for binary states too. Deprecated in js-controller 5.0
6766
'CUSTOM_FULL_VIEW', // `getObjectView('system', 'custom-full', ...)` will return full objects and not only `common.custom` part. Since `js-controller` 5.0
6867
'ADAPTER_GET_OBJECTS_BY_ARRAY', // getForeignObjects supports an array of ids too. Since js-controller 5.0
6968
'CONTROLLER_UI_UPGRADE', // Controller can be updated via sendToHost('upgradeController', ...)

packages/cli/src/lib/setup.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1302,7 +1302,7 @@ async function processCommand(
13021302
try {
13031303
const filePath = await backup.createBackup(name);
13041304
console.log(`Backup created: ${filePath}`);
1305-
console.log('This backup can only be restored with js-controller version 6.1 or higher');
1305+
console.log('This backup can only be restored with js-controller version 7.0 or higher');
13061306
return void callback(EXIT_CODES.NO_ERROR);
13071307
} catch (e) {
13081308
console.log(`Cannot create backup: ${e.message}`);

0 commit comments

Comments
 (0)