matterbridge 1.1.7 → 1.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +24 -0
- package/README.md +1 -1
- package/dist/cli.d.ts +22 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +26 -2
- package/dist/cli.js.map +1 -1
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/matterbridge.d.ts +17 -2
- package/dist/matterbridge.d.ts.map +1 -1
- package/dist/matterbridge.js +387 -102
- package/dist/matterbridge.js.map +1 -1
- package/dist/matterbridgeDevice.d.ts +2 -0
- package/dist/matterbridgeDevice.d.ts.map +1 -1
- package/dist/matterbridgeDevice.js +74 -1
- package/dist/matterbridgeDevice.js.map +1 -1
- package/frontend/build/asset-manifest.json +8 -8
- package/frontend/build/index.html +1 -1
- package/frontend/build/static/css/main.ce1ee9e7.css +2 -0
- package/frontend/build/static/css/main.ce1ee9e7.css.map +1 -0
- package/frontend/build/static/js/453.d855a71b.chunk.js +2 -0
- package/frontend/build/static/js/{453.8ab44547.chunk.js.map → 453.d855a71b.chunk.js.map} +1 -1
- package/frontend/build/static/js/main.cc840fb3.js +3 -0
- package/frontend/build/static/js/{main.e5888ebb.js.LICENSE.txt → main.cc840fb3.js.LICENSE.txt} +19 -0
- package/frontend/build/static/js/main.cc840fb3.js.map +1 -0
- package/package.json +2 -2
- package/frontend/build/static/css/main.6d93e0db.css +0 -2
- package/frontend/build/static/css/main.6d93e0db.css.map +0 -1
- package/frontend/build/static/js/453.8ab44547.chunk.js +0 -2
- package/frontend/build/static/js/main.e5888ebb.js +0 -3
- package/frontend/build/static/js/main.e5888ebb.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,30 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## [1.1.9] - 2024-03-15
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
|
|
9
|
+
- [frontend]: Settings page now controll the global logger level.
|
|
10
|
+
- [frontend]: Frontend got updated to 0.8.1.
|
|
11
|
+
|
|
12
|
+
## [1.1.8] - 2024-03-15
|
|
13
|
+
|
|
14
|
+
### Added
|
|
15
|
+
|
|
16
|
+
- [cli]: Resolve the plugin name from absolute or relative path or from globally installed modules (see the help).
|
|
17
|
+
- [frontend]: Added some fancy stuff still not visible.
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
|
|
21
|
+
- [install]: Fixed the error caused when the controllers disconnect and connect again.
|
|
22
|
+
|
|
23
|
+
## [1.1.7] - 2024-03-14
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
|
|
27
|
+
- [install]: Fixed the install error (thanks https://github.com/khaidakin).
|
|
28
|
+
|
|
5
29
|
## [1.1.6] - 2024-03-14
|
|
6
30
|
|
|
7
31
|
### Added
|
package/README.md
CHANGED
|
@@ -114,7 +114,7 @@ Matterbridge can run as many plugins as you want.
|
|
|
114
114
|
|
|
115
115
|
### Example plugins to show the usage of history in matter
|
|
116
116
|
|
|
117
|
-
[
|
|
117
|
+
[Door plugin with history](https://github.com/Luligu/matterbridge-eve-door)
|
|
118
118
|
|
|
119
119
|
[Motion plugin with history](https://github.com/Luligu/matterbridge-eve-motion)
|
|
120
120
|
|
package/dist/cli.d.ts
CHANGED
|
@@ -1,3 +1,25 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* This file contains the CLI entry point of Matterbridge.
|
|
4
|
+
*
|
|
5
|
+
* @file cli.ts
|
|
6
|
+
* @author Luca Liguori
|
|
7
|
+
* @date 2023-12-29
|
|
8
|
+
* @version 1.0.10
|
|
9
|
+
*
|
|
10
|
+
* Copyright 2023, 2024 Luca Liguori.
|
|
11
|
+
*
|
|
12
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
13
|
+
* you may not use this file except in compliance with the License.
|
|
14
|
+
* You may obtain a copy of the License at
|
|
15
|
+
*
|
|
16
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
17
|
+
*
|
|
18
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
19
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
20
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
21
|
+
* See the License for the specific language governing permissions and
|
|
22
|
+
* limitations under the License. *
|
|
23
|
+
*/
|
|
2
24
|
export {};
|
|
3
25
|
//# sourceMappingURL=cli.d.ts.map
|
package/dist/cli.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;;;;;;;;;;;GAqBG"}
|
package/dist/cli.js
CHANGED
|
@@ -1,13 +1,37 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* This file contains the CLI entry point of Matterbridge.
|
|
4
|
+
*
|
|
5
|
+
* @file cli.ts
|
|
6
|
+
* @author Luca Liguori
|
|
7
|
+
* @date 2023-12-29
|
|
8
|
+
* @version 1.0.10
|
|
9
|
+
*
|
|
10
|
+
* Copyright 2023, 2024 Luca Liguori.
|
|
11
|
+
*
|
|
12
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
13
|
+
* you may not use this file except in compliance with the License.
|
|
14
|
+
* You may obtain a copy of the License at
|
|
15
|
+
*
|
|
16
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
17
|
+
*
|
|
18
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
19
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
20
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
21
|
+
* See the License for the specific language governing permissions and
|
|
22
|
+
* limitations under the License. *
|
|
23
|
+
*/
|
|
2
24
|
import { Matterbridge } from './matterbridge.js';
|
|
3
25
|
async function main() {
|
|
4
26
|
// eslint-disable-next-line no-console
|
|
5
|
-
console.log('
|
|
27
|
+
console.log('CLI: Matterbridge.loadInstance() called');
|
|
6
28
|
await Matterbridge.loadInstance(true);
|
|
29
|
+
// eslint-disable-next-line no-console
|
|
30
|
+
console.log('CLI: Matterbridge.loadInstance() exited');
|
|
7
31
|
}
|
|
8
32
|
process.title = 'matterbridge';
|
|
9
33
|
main().catch((error) => {
|
|
10
34
|
// eslint-disable-next-line no-console
|
|
11
|
-
console.error(`
|
|
35
|
+
console.error(`CLI: Matterbridge.loadInstance() failed with error: ${error}`);
|
|
12
36
|
});
|
|
13
37
|
//# sourceMappingURL=cli.js.map
|
package/dist/cli.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,KAAK,UAAU,IAAI;IACjB,sCAAsC;IACtC,OAAO,CAAC,GAAG,CAAC,yCAAyC,CAAC,CAAC;IACvD,MAAM,YAAY,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC;IACtC,sCAAsC;IACtC,OAAO,CAAC,GAAG,CAAC,yCAAyC,CAAC,CAAC;AACzD,CAAC;AAED,OAAO,CAAC,KAAK,GAAG,cAAc,CAAC;AAE/B,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,sCAAsC;IACtC,OAAO,CAAC,KAAK,CAAC,uDAAuD,KAAK,EAAE,CAAC,CAAC;AAChF,CAAC,CAAC,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -36,11 +36,13 @@ export * from './ColorControlServer.js';
|
|
|
36
36
|
export * from './TvocCluster.js';
|
|
37
37
|
async function main() {
|
|
38
38
|
// eslint-disable-next-line no-console
|
|
39
|
-
console.log('
|
|
39
|
+
console.log('MAIN: Matterbridge.loadInstance() called');
|
|
40
40
|
await Matterbridge.loadInstance();
|
|
41
|
+
// eslint-disable-next-line no-console
|
|
42
|
+
console.log('MAIN: Matterbridge.loadInstance() exited');
|
|
41
43
|
}
|
|
42
44
|
main().catch((error) => {
|
|
43
45
|
// eslint-disable-next-line no-console
|
|
44
|
-
console.error(`
|
|
46
|
+
console.error(`MAIN: Matterbridge.loadInstance() failed with error: ${error}`);
|
|
45
47
|
});
|
|
46
48
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,8BAA8B,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,cAAc,qCAAqC,CAAC;AACpD,cAAc,sCAAsC,CAAC;AACrD,cAAc,kCAAkC,CAAC;AACjD,cAAc,uCAAuC,CAAC;AAEtD,cAAc,gBAAgB,CAAC;AAE/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,yBAAyB,CAAC;AACxC,cAAc,oCAAoC,CAAC;AACnD,cAAc,kCAAkC,CAAC;AACjD,cAAc,wBAAwB,CAAC;AACvC,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AAEjC,KAAK,UAAU,IAAI;IACjB,sCAAsC;IACtC,OAAO,CAAC,GAAG,CAAC
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,8BAA8B,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,cAAc,qCAAqC,CAAC;AACpD,cAAc,sCAAsC,CAAC;AACrD,cAAc,kCAAkC,CAAC;AACjD,cAAc,uCAAuC,CAAC;AAEtD,cAAc,gBAAgB,CAAC;AAE/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,yBAAyB,CAAC;AACxC,cAAc,oCAAoC,CAAC;AACnD,cAAc,kCAAkC,CAAC;AACjD,cAAc,wBAAwB,CAAC;AACvC,cAAc,yBAAyB,CAAC;AACxC,cAAc,kBAAkB,CAAC;AAEjC,KAAK,UAAU,IAAI;IACjB,sCAAsC;IACtC,OAAO,CAAC,GAAG,CAAC,0CAA0C,CAAC,CAAC;IACxD,MAAM,YAAY,CAAC,YAAY,EAAE,CAAC;IAClC,sCAAsC;IACtC,OAAO,CAAC,GAAG,CAAC,0CAA0C,CAAC,CAAC;AAC1D,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,sCAAsC;IACtC,OAAO,CAAC,KAAK,CAAC,wDAAwD,KAAK,EAAE,CAAC,CAAC;AACjF,CAAC,CAAC,CAAC"}
|
package/dist/matterbridge.d.ts
CHANGED
|
@@ -42,7 +42,10 @@ export declare class Matterbridge {
|
|
|
42
42
|
homeDirectory: string;
|
|
43
43
|
rootDirectory: string;
|
|
44
44
|
matterbridgeDirectory: string;
|
|
45
|
+
matterbridgePluginDirectory: string;
|
|
45
46
|
matterbridgeVersion: string;
|
|
47
|
+
matterbridgeLatestVersion: string;
|
|
48
|
+
globalModulesDir: string;
|
|
46
49
|
bridgeMode: 'bridge' | 'childbridge' | 'controller' | '';
|
|
47
50
|
debugEnabled: boolean;
|
|
48
51
|
private log;
|
|
@@ -51,7 +54,8 @@ export declare class Matterbridge {
|
|
|
51
54
|
private registeredDevices;
|
|
52
55
|
private nodeStorage;
|
|
53
56
|
private nodeContext;
|
|
54
|
-
private
|
|
57
|
+
private expressApp;
|
|
58
|
+
private expressServer;
|
|
55
59
|
private storageManager;
|
|
56
60
|
private matterbridgeContext;
|
|
57
61
|
private mattercontrollerContext;
|
|
@@ -66,7 +70,7 @@ export declare class Matterbridge {
|
|
|
66
70
|
* If an instance already exists, return that instance.
|
|
67
71
|
* @returns The loaded instance of the Matterbridge class.
|
|
68
72
|
*/
|
|
69
|
-
static loadInstance(
|
|
73
|
+
static loadInstance(initialize?: boolean): Promise<Matterbridge>;
|
|
70
74
|
/**
|
|
71
75
|
* Initializes the Matterbridge application.
|
|
72
76
|
*
|
|
@@ -84,6 +88,7 @@ export declare class Matterbridge {
|
|
|
84
88
|
* @returns {Promise<void>} A promise that resolves when the command line arguments have been processed.
|
|
85
89
|
*/
|
|
86
90
|
private parseCommandLine;
|
|
91
|
+
private resolvePluginName;
|
|
87
92
|
/**
|
|
88
93
|
* Loads a plugin from the specified package.json file path.
|
|
89
94
|
* @param packageJsonPath - The path to the package.json file of the plugin.
|
|
@@ -96,6 +101,10 @@ export declare class Matterbridge {
|
|
|
96
101
|
* When either of these signals are received, the cleanup method is called with an appropriate message.
|
|
97
102
|
*/
|
|
98
103
|
private registerSignalHandlers;
|
|
104
|
+
/**
|
|
105
|
+
* Restarts the process by spawning a new process and exiting the current process.
|
|
106
|
+
*/
|
|
107
|
+
private restartProcess;
|
|
99
108
|
/**
|
|
100
109
|
* Performs cleanup operations before shutting down Matterbridge.
|
|
101
110
|
* @param message - The reason for the cleanup.
|
|
@@ -226,6 +235,12 @@ export declare class Matterbridge {
|
|
|
226
235
|
* Stops the Matter server and associated controllers.
|
|
227
236
|
*/
|
|
228
237
|
private stopMatter;
|
|
238
|
+
/**
|
|
239
|
+
* Retrieves the latest version of a package from the npm registry.
|
|
240
|
+
* @param packageName - The name of the package.
|
|
241
|
+
* @returns A Promise that resolves to the latest version of the package.
|
|
242
|
+
*/
|
|
243
|
+
private getLatestVersion;
|
|
229
244
|
/**
|
|
230
245
|
* Logs the node and system information.
|
|
231
246
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"matterbridge.d.ts","sourceRoot":"","sources":["../src/matterbridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,kBAAkB,EAAgC,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"matterbridge.d.ts","sourceRoot":"","sources":["../src/matterbridge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,kBAAkB,EAAgC,MAAM,yBAAyB,CAAC;AA4E3F,UAAU,iBAAiB;IACzB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;CACtB;AAMD;;GAEG;AACH,qBAAa,YAAY;IAChB,iBAAiB,EAAE,iBAAiB,CAYzC;IACK,aAAa,EAAE,MAAM,CAAM;IAC3B,aAAa,EAAE,MAAM,CAAM;IAC3B,qBAAqB,EAAE,MAAM,CAAM;IACnC,2BAA2B,EAAE,MAAM,CAAM;IACzC,mBAAmB,EAAE,MAAM,CAAM;IACjC,yBAAyB,EAAE,MAAM,CAAM;IACvC,gBAAgB,EAAE,MAAM,CAAM;IAE9B,UAAU,EAAE,QAAQ,GAAG,aAAa,GAAG,YAAY,GAAG,EAAE,CAAM;IAC9D,YAAY,UAAS;IAE5B,OAAO,CAAC,GAAG,CAAc;IACzB,OAAO,CAAC,iBAAiB,CAAS;IAClC,OAAO,CAAC,iBAAiB,CAA0B;IACnD,OAAO,CAAC,iBAAiB,CAA0B;IACnD,OAAO,CA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