@webos-tools/cli 3.2.0 → 3.2.2
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 +18 -5
- package/bin/ares-config.js +1 -1
- package/bin/ares-device-info.js +0 -0
- package/bin/ares-device.js +0 -0
- package/bin/ares-generate.js +0 -0
- package/bin/ares-inspect.js +0 -0
- package/bin/ares-install.js +0 -0
- package/bin/ares-launch.js +0 -0
- package/bin/ares-log.js +1 -1
- package/bin/ares-novacom.js +0 -0
- package/bin/ares-package.js +0 -0
- package/bin/ares-pull.js +0 -0
- package/bin/ares-push.js +0 -0
- package/bin/ares-server.js +0 -0
- package/bin/ares-setup-device.js +6 -10
- package/bin/ares-shell.js +0 -0
- package/bin/ares.js +1 -1
- package/files/conf/ares.json +1 -2
- package/files/conf/novacom-devices.json +2 -2
- package/files/conf-base/env/sdk-apollo.json +1 -1
- package/files/conf-base/profile/config-apollo.json +1 -1
- package/files/conf-base/profile/config-ose.json +1 -1
- package/files/conf-base/query/signage/query-app.json +1 -1
- package/files/conf-base/query/signage/query-service.json +1 -1
- package/files/help/ares-launch.help +1 -1
- package/files/templates/ose-sdk-templates/icon/icon.png +0 -0
- package/files/templates/signage-sdk-templates/Backlight_Scheduling/index.html +1 -1
- package/files/templates/signage-sdk-templates/Backlight_Scheduling/scheduler.js +2 -3
- package/files/templates/signage-sdk-templates/File_Explorer/index.html +1 -33
- package/files/templates/signage-sdk-templates/File_Explorer/js/Root.js +0 -9
- package/files/templates/tv-sdk-templates/js-service/helloworld_service.js +0 -0
- package/files/templates/tv-sdk-templates/webicon/icon.png +0 -0
- package/files/templates/tv-sdk-templates/webicon/largeIcon.png +0 -0
- package/lib/base/cli-appdata.js +1 -0
- package/lib/base/novacom.js +4 -4
- package/lib/base/setup-device.js +2 -2
- package/lib/generator.js +1 -1
- package/lib/package.js +60 -8
- package/lib/shell.js +1 -1
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
- package/spec/jsSpecs/ares-generate.spec.js +4 -8
- package/spec/jsSpecs/ares-log.spec.js +1 -1
- package/spec/jsSpecs/ares-setup-device.spec.js +1 -0
- package/spec/tempFiles/nativeApp/auto/pkg_arm64/GLES2 +0 -0
- package/spec/tempFiles/nativeApp/ose/pkg_arm/Hello +0 -0
- package/spec/tempFiles/nativeApp/oseEmul/pkg_x86/Hello +0 -0
- package/spec/tempFiles/nativeApp/rsi/pkg_x86/GLES2 +0 -0
- package/spec/test_data/ares-generate.json +1 -34
- package/webos-tools-cli-3.2.0.tgz +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## 3.2.2 (February 26, 2026)
|
|
2
|
+
|
|
3
|
+
### ares-package
|
|
4
|
+
|
|
5
|
+
* Fixed the issue where ares-package failed to package an app correctly in `Signage` profile.
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
## 3.2.1 (April 2, 2025)
|
|
9
|
+
|
|
10
|
+
### ares-package
|
|
11
|
+
|
|
12
|
+
* Fixed a bug related to the use of the `sign` and `certificate` options in `tv` profile.
|
|
13
|
+
|
|
14
|
+
|
|
1
15
|
## 3.2.0 (December 24, 2024)
|
|
2
16
|
|
|
3
17
|
### ares-config
|
|
@@ -33,7 +47,6 @@
|
|
|
33
47
|
* Fixed a bug that device name can not be added with "-".
|
|
34
48
|
|
|
35
49
|
|
|
36
|
-
|
|
37
50
|
## 3.1.2 (August 07, 2024)
|
|
38
51
|
### ares-config
|
|
39
52
|
* Added a new apollo profile for apollo platform.
|
|
@@ -44,17 +57,17 @@
|
|
|
44
57
|
|
|
45
58
|
## 3.1.1 (July 15, 2024)
|
|
46
59
|
### ares-inspect
|
|
47
|
-
* Fixed a bug that ares-inspect --service display error message on webOS TV 4.5 or lower
|
|
60
|
+
* Fixed a bug that ares-inspect --service display error message on webOS TV 4.5 or lower
|
|
48
61
|
|
|
49
62
|
|
|
50
63
|
## 3.1.0 (July 12, 2024)
|
|
51
64
|
### ares-generate
|
|
52
|
-
* Fixed a bug that can not generate without --template option
|
|
65
|
+
* Fixed a bug that can not generate without --template option
|
|
53
66
|
|
|
54
67
|
### ares-setup-device
|
|
55
68
|
* Enhance usability of --add option.
|
|
56
|
-
* Enhance emulator remove usability
|
|
57
|
-
* Change default device information of TV profile (user: prisoner, port:9922)
|
|
69
|
+
* Enhance emulator remove usability
|
|
70
|
+
* Change default device information of TV profile (user: prisoner, port:9922)
|
|
58
71
|
* Change device name validation logic that accepts all characters except "$" & "%"
|
|
59
72
|
|
|
60
73
|
### common
|
package/bin/ares-config.js
CHANGED
package/bin/ares-device-info.js
CHANGED
|
File without changes
|
package/bin/ares-device.js
CHANGED
|
File without changes
|
package/bin/ares-generate.js
CHANGED
|
File without changes
|
package/bin/ares-inspect.js
CHANGED
|
File without changes
|
package/bin/ares-install.js
CHANGED
|
File without changes
|
package/bin/ares-launch.js
CHANGED
|
File without changes
|
package/bin/ares-log.js
CHANGED
package/bin/ares-novacom.js
CHANGED
|
File without changes
|
package/bin/ares-package.js
CHANGED
|
File without changes
|
package/bin/ares-pull.js
CHANGED
|
File without changes
|
package/bin/ares-push.js
CHANGED
|
File without changes
|
package/bin/ares-server.js
CHANGED
|
File without changes
|
package/bin/ares-setup-device.js
CHANGED
|
@@ -230,7 +230,7 @@ function _queryAddRemove(ssdpDevices, next) {
|
|
|
230
230
|
when: function(answers) {
|
|
231
231
|
return (["remove"].indexOf(answers.op) !== -1 && !ssdpDevice);
|
|
232
232
|
}
|
|
233
|
-
},{
|
|
233
|
+
}, {
|
|
234
234
|
type: "list",
|
|
235
235
|
name: "device_name",
|
|
236
236
|
message: "Select a device",
|
|
@@ -328,7 +328,7 @@ function _queryDeviceInfo(selDevice, next) {
|
|
|
328
328
|
return idx;
|
|
329
329
|
},
|
|
330
330
|
when: function(answers) {
|
|
331
|
-
return _needInq(mode)(inqChoices) && answers.user ===
|
|
331
|
+
return _needInq(mode)(inqChoices) && answers.user === "root";
|
|
332
332
|
}
|
|
333
333
|
}, {
|
|
334
334
|
type: "password",
|
|
@@ -347,8 +347,7 @@ function _queryDeviceInfo(selDevice, next) {
|
|
|
347
347
|
when: function(answers) {
|
|
348
348
|
return _needInq(mode)(inqChoices) && (answers.auth_type === "ssh key");
|
|
349
349
|
}
|
|
350
|
-
},
|
|
351
|
-
{
|
|
350
|
+
}, {
|
|
352
351
|
type: "confirm",
|
|
353
352
|
name: "default",
|
|
354
353
|
message: "Set default ?",
|
|
@@ -381,16 +380,14 @@ function _queryDeviceInfo(selDevice, next) {
|
|
|
381
380
|
username: answers.user,
|
|
382
381
|
default: answers.default
|
|
383
382
|
};
|
|
384
|
-
|
|
385
383
|
|
|
386
|
-
if (answers.
|
|
387
|
-
user !== 'prisoner' && ["add", "modify"].includes(mode)) {
|
|
384
|
+
if (answers.user !== 'prisoner' && ["add", "modify"].includes(mode)) {
|
|
388
385
|
if (answers.auth_type && answers.auth_type === "password") {
|
|
389
386
|
inDevice.password = answers.password;
|
|
390
387
|
inDevice.privateKey = "@DELETE@";
|
|
391
388
|
inDevice.passphrase = "@DELETE@";
|
|
392
389
|
inDevice.privateKeyName = "@DELETE@";
|
|
393
|
-
} else if ((answers.auth_type && answers.auth_type === "ssh key") ||
|
|
390
|
+
} else if ((answers.auth_type && answers.auth_type === "ssh key") || answers.user === "developer") {
|
|
394
391
|
inDevice.password = "@DELETE@";
|
|
395
392
|
inDevice.privateKey = {
|
|
396
393
|
"openSsh": answers.ssh_key || "webos_emul"
|
|
@@ -417,7 +414,7 @@ function _queryDeviceInfo(selDevice, next) {
|
|
|
417
414
|
setupDevice.showDeviceList.bind(this),
|
|
418
415
|
], function(err, results) {
|
|
419
416
|
if (err) {
|
|
420
|
-
return next(err
|
|
417
|
+
return next(err);
|
|
421
418
|
}
|
|
422
419
|
if(results[2] && results[2].msg){
|
|
423
420
|
console.log(results[2].msg);
|
|
@@ -574,4 +571,3 @@ function reParse(argv, mode) {
|
|
|
574
571
|
}
|
|
575
572
|
return argv
|
|
576
573
|
}
|
|
577
|
-
|
package/bin/ares-shell.js
CHANGED
|
File without changes
|
package/bin/ares.js
CHANGED
|
@@ -119,7 +119,7 @@ function display (next) {
|
|
|
119
119
|
for (const arg in argv) {
|
|
120
120
|
if (Object.hasOwnProperty.call(commandsList, 'ares-'+ arg) && fs.existsSync(path.join(__dirname, 'ares-'+ arg + '.js'))) {
|
|
121
121
|
if (commandsList['ares-'+ arg].profile && !commandsList['ares-'+ arg].profile.includes(profile)) {
|
|
122
|
-
|
|
122
|
+
return next(errHndl.getErrMsg("NOT_SUPPORT_COMMOND", profile));
|
|
123
123
|
} else {
|
|
124
124
|
help.display('ares-'+arg, appdata.getConfig(true).profile);
|
|
125
125
|
found = true;
|
package/files/conf/ares.json
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
"description": "Configure webOS CLI"
|
|
4
4
|
},
|
|
5
5
|
"ares-device": {
|
|
6
|
-
"profile": ["ose", "apollo", "tv"],
|
|
7
6
|
"description": "Display the device information"
|
|
8
7
|
},
|
|
9
8
|
"ares-generate": {
|
|
@@ -47,4 +46,4 @@
|
|
|
47
46
|
"profile": ["ose","apollo"],
|
|
48
47
|
"description": "Open a device terminal or run a command"
|
|
49
48
|
}
|
|
50
|
-
}
|
|
49
|
+
}
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"profile": "apollo",
|
|
39
39
|
"name": "emulator",
|
|
40
40
|
"type": "starfish",
|
|
41
|
-
"description": "LG webOS
|
|
41
|
+
"description": "LG webOS Apollo Emulator",
|
|
42
42
|
"host": "127.0.0.1",
|
|
43
43
|
"port": 6622,
|
|
44
44
|
"username": "developer",
|
|
@@ -66,4 +66,4 @@
|
|
|
66
66
|
"noPortForwarding":false,
|
|
67
67
|
"indelible": true
|
|
68
68
|
}
|
|
69
|
-
]
|
|
69
|
+
]
|
|
File without changes
|
|
@@ -82,7 +82,7 @@ function getTime() {
|
|
|
82
82
|
"onFailure": function (err) {
|
|
83
83
|
console.log("onFailure : errorMessage = " + err.errorMessage);
|
|
84
84
|
}
|
|
85
|
-
});
|
|
85
|
+
});
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
// If parameter value(time value) and current time is matched, do backlight scheduling
|
|
@@ -119,5 +119,4 @@ function do_scheduling_by_IDCAP(hour, minute) {
|
|
|
119
119
|
}
|
|
120
120
|
});
|
|
121
121
|
}
|
|
122
|
-
}
|
|
123
|
-
|
|
122
|
+
}
|
|
@@ -6,39 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
<script src = ./js/definition.js></script>
|
|
8
8
|
<script src = ./js/Root.js></script>
|
|
9
|
-
<script src = ./js/explorer.js></script>
|
|
10
|
-
<script src = ./js/mainController.js></script>
|
|
11
|
-
<script src = ./js/explorerController.js></script>
|
|
12
|
-
|
|
13
|
-
<link rel="stylesheet" type="text/css" href="./style.css">
|
|
14
|
-
|
|
15
|
-
</head>
|
|
16
|
-
|
|
17
|
-
<body onload = "init()">
|
|
18
|
-
<div id = "menu_popup"></div>
|
|
19
|
-
|
|
20
|
-
<div id="currentPos"></div>
|
|
21
|
-
<div id="filetitle">
|
|
22
|
-
<div id ="filetitle_name">Name</div>
|
|
23
|
-
<div id ="filetitle_type">Type</div>
|
|
24
|
-
<div id ="filetitle_size">Size</div>
|
|
25
|
-
<div id ="filetitle_ctime">Create Time</div>
|
|
26
|
-
<div id ="filetitle_atime">Access Time</div>
|
|
27
|
-
<div id ="filetitle_mtime">Modify Time</div>
|
|
28
|
-
</div>
|
|
29
|
-
|
|
30
|
-
<div id ="fileList_name"></div>
|
|
31
|
-
<div id ="fileList_type"></div>
|
|
32
|
-
<div id ="fileList_size"></div>
|
|
33
|
-
<div id ="fileList_ctime"></div>
|
|
34
|
-
<div id ="fileList_atime"></div>
|
|
35
|
-
<div id ="fileList_mtime"></div>
|
|
36
|
-
|
|
37
|
-
<div id="fileInfo">
|
|
38
|
-
<div id="status"></div>
|
|
39
|
-
<div id="contents"></div>
|
|
40
|
-
</div>
|
|
41
9
|
|
|
42
10
|
|
|
43
11
|
</body>
|
|
44
|
-
</html>
|
|
12
|
+
</html>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/lib/base/cli-appdata.js
CHANGED
package/lib/base/novacom.js
CHANGED
|
@@ -638,9 +638,9 @@ const async = require('async'),
|
|
|
638
638
|
if (Array.isArray(errorMessages) && errorMessages.length > 0) {
|
|
639
639
|
for (const index in errorMessages) {
|
|
640
640
|
log.error(
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
641
|
+
"novacom#Session()#begin() " + errorMessages[index].heading,
|
|
642
|
+
errorMessages[index].message
|
|
643
|
+
);
|
|
644
644
|
}
|
|
645
645
|
}
|
|
646
646
|
if (this.errorImmediate) clearImmediate(this.errorImmediate);
|
|
@@ -987,7 +987,7 @@ const async = require('async'),
|
|
|
987
987
|
chStream.on('close', function() {
|
|
988
988
|
log.silly("novacom#Session()#run()", "event close (cmd:" + cmd + ")");
|
|
989
989
|
if (err === undefined) {
|
|
990
|
-
|
|
990
|
+
setImmediate(next);
|
|
991
991
|
}
|
|
992
992
|
});
|
|
993
993
|
|
package/lib/base/setup-device.js
CHANGED
|
@@ -204,7 +204,7 @@ const async = require('async'),
|
|
|
204
204
|
async.series([
|
|
205
205
|
resolver.load.bind(resolver),
|
|
206
206
|
resolver.modifyDeviceFile.bind(resolver, mode, inDevice),
|
|
207
|
-
this.showDeviceList.bind(this)
|
|
207
|
+
this.showDeviceList.bind(this)
|
|
208
208
|
], function(err, results) {
|
|
209
209
|
if (err) {
|
|
210
210
|
return next(err);
|
|
@@ -229,8 +229,8 @@ const async = require('async'),
|
|
|
229
229
|
resolver.load.bind(resolver),
|
|
230
230
|
resolver.list.bind(resolver),
|
|
231
231
|
function(devices, next) {
|
|
232
|
+
devices.sort((device1, device2) => device2.index - device1.index);
|
|
232
233
|
if (Array.isArray(devices)) {
|
|
233
|
-
devices.sort((device1, device2) => device2.index - device1.index);
|
|
234
234
|
devices.forEach(function(device) {
|
|
235
235
|
const conn = device.conn.concat([]),
|
|
236
236
|
info = (device.username && device.host && device.port) ? device.username + '@' + device.host + ':' + device.port : device.id,
|
package/lib/generator.js
CHANGED
package/lib/package.js
CHANGED
|
@@ -25,8 +25,13 @@ const ar = require('ar-async'),
|
|
|
25
25
|
temp = require('temp'),
|
|
26
26
|
uglify = require('terser'),
|
|
27
27
|
util = require('util'),
|
|
28
|
+
// zlib = require('zlib'),
|
|
29
|
+
// tarFilterPack = require('./tar-filter-pack'),
|
|
28
30
|
errHndl = require('./base/error-handler'),
|
|
29
|
-
tar = require('tar')
|
|
31
|
+
tar = require('tar'),
|
|
32
|
+
commonTools = require('./base/common-tools');
|
|
33
|
+
|
|
34
|
+
const appdata = commonTools.appdata;
|
|
30
35
|
|
|
31
36
|
(function() {
|
|
32
37
|
log.heading = 'packager';
|
|
@@ -62,8 +67,6 @@ const ar = require('ar-async'),
|
|
|
62
67
|
this.nativecmd = false;
|
|
63
68
|
this.minify = true;
|
|
64
69
|
this.excludeFiles = [];
|
|
65
|
-
this.rom = false;
|
|
66
|
-
this.encrypt = false;
|
|
67
70
|
this.sign = null;
|
|
68
71
|
this.certificate = null;
|
|
69
72
|
this.appCount = 0;
|
|
@@ -132,7 +135,7 @@ const ar = require('ar-async'),
|
|
|
132
135
|
|
|
133
136
|
if (options && Object.prototype.hasOwnProperty.call(options, 'remainPlainIPK')) {
|
|
134
137
|
this.remainPlainIPK = options.remainPlainIPK;
|
|
135
|
-
}
|
|
138
|
+
}
|
|
136
139
|
|
|
137
140
|
if (options && Object.prototype.hasOwnProperty.call(options, 'sign')) {
|
|
138
141
|
if (!fs.existsSync(path.resolve(options.sign))) {
|
|
@@ -1283,6 +1286,7 @@ const ar = require('ar-async'),
|
|
|
1283
1286
|
createDataHash.bind(this, tempCtrlDir, dataTgzFile),
|
|
1284
1287
|
createCertificateHash.bind(this, tempCtrlDir),
|
|
1285
1288
|
createControlFile.bind(this, tempCtrlDir, false),
|
|
1289
|
+
createSign.bind(this, tempCtrlDir, dataTgzFile),
|
|
1286
1290
|
createControlSignFile.bind(this, tempCtrlDir),
|
|
1287
1291
|
makeTgz.bind(this, tempCtrlDir, ctrlTgzFile),
|
|
1288
1292
|
createDebianBinary.bind(this, tempDir),
|
|
@@ -1365,6 +1369,9 @@ const ar = require('ar-async'),
|
|
|
1365
1369
|
}
|
|
1366
1370
|
|
|
1367
1371
|
function createDataHash(dstDir, dataTgzPath, next) {
|
|
1372
|
+
// This function applies only to the signage profile.
|
|
1373
|
+
if (appdata.config.profile !== 'signage') return setImmediate(next);
|
|
1374
|
+
|
|
1368
1375
|
const self = this;
|
|
1369
1376
|
log.verbose("package#createDataHash()", "Create data hash");
|
|
1370
1377
|
|
|
@@ -1401,6 +1408,9 @@ const ar = require('ar-async'),
|
|
|
1401
1408
|
}
|
|
1402
1409
|
|
|
1403
1410
|
function createCertificateHash(dstDir, next) {
|
|
1411
|
+
// This function applies only to the signage profile.
|
|
1412
|
+
if (appdata.config.profile !== 'signage') return setImmediate(next);
|
|
1413
|
+
|
|
1404
1414
|
const self = this;
|
|
1405
1415
|
try {
|
|
1406
1416
|
if (!self.certificate) {
|
|
@@ -1448,11 +1458,12 @@ const ar = require('ar-async'),
|
|
|
1448
1458
|
];
|
|
1449
1459
|
|
|
1450
1460
|
// To IPK security (SEAL)
|
|
1451
|
-
|
|
1461
|
+
// The data hashs apply only to the signage profile.
|
|
1462
|
+
if (this.sign !== null && appdata.config.profile === 'signage') {
|
|
1452
1463
|
lines.push('Application-Hash-Algorithm: SHA-256');
|
|
1453
1464
|
lines.push('Application-Hash: ' + this.dataHash);
|
|
1454
1465
|
}
|
|
1455
|
-
if (this.certificate !== null) {
|
|
1466
|
+
if (this.certificate !== null && appdata.config.profile === 'signage') {
|
|
1456
1467
|
lines.push('Certificate-Hash: ' + this.certificateHash);
|
|
1457
1468
|
lines.push('Signature-Algorithm: RSA');
|
|
1458
1469
|
}
|
|
@@ -1465,6 +1476,9 @@ const ar = require('ar-async'),
|
|
|
1465
1476
|
}
|
|
1466
1477
|
|
|
1467
1478
|
function createControlSignFile(ctrlDir, next) {
|
|
1479
|
+
// This function applies only to the signage profile.
|
|
1480
|
+
if (appdata.config.profile !== 'signage') return setImmediate(next);
|
|
1481
|
+
|
|
1468
1482
|
try {
|
|
1469
1483
|
if (this.sign === null) {
|
|
1470
1484
|
log.verbose("package#createControlSignFile()", "App signing is skipped");
|
|
@@ -1490,7 +1504,7 @@ const ar = require('ar-async'),
|
|
|
1490
1504
|
let controlSigner = crypto.createSign('sha256')
|
|
1491
1505
|
controlSigner.update(controlData);
|
|
1492
1506
|
controlSigner.end();
|
|
1493
|
-
controlSign = controlSigner.sign(privateKey);
|
|
1507
|
+
const controlSign = controlSigner.sign(privateKey);
|
|
1494
1508
|
let base64data = Buffer.from(controlSign).toString('base64');
|
|
1495
1509
|
|
|
1496
1510
|
fs.writeFile(controlSignFilePath, base64data, next);
|
|
@@ -1500,6 +1514,44 @@ const ar = require('ar-async'),
|
|
|
1500
1514
|
}
|
|
1501
1515
|
}
|
|
1502
1516
|
|
|
1517
|
+
function createSign(dstDir, dataTgzPath, next) {
|
|
1518
|
+
// This function does not apply to the signage profile.
|
|
1519
|
+
if (appdata.config.profile === 'signage') return setImmediate(next);
|
|
1520
|
+
|
|
1521
|
+
if ((!this.sign) || (!this.certificate)) {
|
|
1522
|
+
log.verbose("package#createSign()", "App signing is skipped");
|
|
1523
|
+
return setImmediate(next);
|
|
1524
|
+
}
|
|
1525
|
+
|
|
1526
|
+
const sigFilePath = path.join(dstDir, 'data.tar.gz.sha256.txt'),
|
|
1527
|
+
keyPath = path.resolve(this.sign),
|
|
1528
|
+
crtPath = path.resolve(this.certificate);
|
|
1529
|
+
|
|
1530
|
+
log.verbose("package#createSign()", "dataTgzPath:" + dataTgzPath + ", sigfile:" + sigFilePath);
|
|
1531
|
+
log.verbose("package#createSign()", "keyPath:" + keyPath + ", crtPath:" + crtPath);
|
|
1532
|
+
|
|
1533
|
+
try {
|
|
1534
|
+
// Create certificate to tmp/ctrl directory
|
|
1535
|
+
shelljs.cp('-f', crtPath, dstDir);
|
|
1536
|
+
|
|
1537
|
+
// Create signature and write data.tar.gz.sha256.txt
|
|
1538
|
+
const privateKey = fs.readFileSync(keyPath, 'utf-8'),
|
|
1539
|
+
dataFile = fs.readFileSync(dataTgzPath), // data.tar.gz
|
|
1540
|
+
signer = crypto.createSign('sha256');
|
|
1541
|
+
|
|
1542
|
+
signer.update(dataFile);
|
|
1543
|
+
signer.end();
|
|
1544
|
+
|
|
1545
|
+
const signature = signer.sign(privateKey),
|
|
1546
|
+
buff = Buffer.from(signature),
|
|
1547
|
+
base64data = buff.toString('base64');
|
|
1548
|
+
|
|
1549
|
+
fs.writeFile(sigFilePath, base64data, next);
|
|
1550
|
+
} catch (err) {
|
|
1551
|
+
setImmediate(next, err);
|
|
1552
|
+
}
|
|
1553
|
+
}
|
|
1554
|
+
|
|
1503
1555
|
function createDebianBinary(dstDir, next) {
|
|
1504
1556
|
const dstFilePath = path.join(dstDir, "debian-binary");
|
|
1505
1557
|
log.verbose("package#createDebianBinary()", dstFilePath);
|
|
@@ -1706,7 +1758,7 @@ const ar = require('ar-async'),
|
|
|
1706
1758
|
this.rscCount++;
|
|
1707
1759
|
log.verbose("FOUND resourceinfo.json, rscCount " + this.rscCount);
|
|
1708
1760
|
if (this.appCount > 0 || this.svcDir && this.svcDir.length > 0) {
|
|
1709
|
-
|
|
1761
|
+
return callback(errHndl.getErrMsg("NOT_PACKAGE_WITH_RESOURCE"));
|
|
1710
1762
|
}
|
|
1711
1763
|
this.resources = this.resources || [];
|
|
1712
1764
|
const rsc = {};
|
package/lib/shell.js
CHANGED
|
@@ -34,7 +34,7 @@ const async = require('async'),
|
|
|
34
34
|
},
|
|
35
35
|
function(next) {
|
|
36
36
|
if (options && options.display && !options.sessionCall) {
|
|
37
|
-
|
|
37
|
+
return setImmediate(next, errHndl.getErrMsg("NOT_SUPPORT_SESSION"), {});
|
|
38
38
|
}
|
|
39
39
|
next();
|
|
40
40
|
},
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webos-tools/cli",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.2",
|
|
4
4
|
"lockfileVersion": 2,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@webos-tools/cli",
|
|
9
|
-
"version": "3.2.
|
|
9
|
+
"version": "3.2.1",
|
|
10
10
|
"hasInstallScript": true,
|
|
11
11
|
"license": "Apache-2.0",
|
|
12
12
|
"os": [
|
package/package.json
CHANGED
|
@@ -100,7 +100,7 @@ describe(aresCmd +' --property', function() {
|
|
|
100
100
|
});
|
|
101
101
|
|
|
102
102
|
it('Set the properties of packageinfo.json', function(done) {
|
|
103
|
-
if (options.profile
|
|
103
|
+
if (options.profile === "ose" || options.profile === "apollo") {
|
|
104
104
|
pending(options.skipTxt);
|
|
105
105
|
}
|
|
106
106
|
|
|
@@ -157,7 +157,7 @@ describe(aresCmd +' --property', function() {
|
|
|
157
157
|
});
|
|
158
158
|
|
|
159
159
|
it('Set the properties of qmlappinfo.json', function(done) {
|
|
160
|
-
if (options.profile
|
|
160
|
+
if (options.profile === "tv" || options.profile === "apollo") {
|
|
161
161
|
pending(options.skipTxt);
|
|
162
162
|
}
|
|
163
163
|
|
|
@@ -222,7 +222,7 @@ describe(aresCmd + ' --template', function() {
|
|
|
222
222
|
});
|
|
223
223
|
|
|
224
224
|
it('packageinfo : packageinfo.json for webOS package', function(done) {
|
|
225
|
-
if (options.profile
|
|
225
|
+
if (options.profile === "ose" || options.profile === "apollo") {
|
|
226
226
|
pending(options.skipTxt);
|
|
227
227
|
}
|
|
228
228
|
|
|
@@ -249,10 +249,6 @@ describe(aresCmd + ' --template', function() {
|
|
|
249
249
|
});
|
|
250
250
|
|
|
251
251
|
it('hosted_webapp : generate hosted template app', function(done) {
|
|
252
|
-
if (options.profile == "signage") {
|
|
253
|
-
pending(options.skipTxt);
|
|
254
|
-
}
|
|
255
|
-
|
|
256
252
|
const url = "http://www.google.com";
|
|
257
253
|
exec(cmd + ` -t hosted_webapp -p "url=${url}" ${sampleAppPath}`, function(error, stdout, stderr) {
|
|
258
254
|
if (stderr && stderr.length > 0) {
|
|
@@ -274,7 +270,7 @@ describe(aresCmd + ' --template', function() {
|
|
|
274
270
|
});
|
|
275
271
|
|
|
276
272
|
it('qmlapp : generate qml template app', function(done) {
|
|
277
|
-
if (options.profile
|
|
273
|
+
if (options.profile === "tv" || options.profile === "apollo") {
|
|
278
274
|
pending(options.skipTxt);
|
|
279
275
|
}
|
|
280
276
|
|
|
@@ -121,7 +121,7 @@ describe(aresCmd + " -sd", function() {
|
|
|
121
121
|
exec(cmd + ` -sd ${targetLogDaemon}`, function(error, stdout, stderr) {
|
|
122
122
|
if (stderr && stderr.length > 0) {
|
|
123
123
|
common.detectNodeMessage(stderr);
|
|
124
|
-
}
|
|
124
|
+
}
|
|
125
125
|
expect(stdout).toContain(`CLI's current logging daemon : ${targetLogDaemon}`);
|
|
126
126
|
done();
|
|
127
127
|
});
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -54,38 +54,5 @@
|
|
|
54
54
|
"jsservice": "js_service",
|
|
55
55
|
"webappinfo": ["appinfo.json"]
|
|
56
56
|
}
|
|
57
|
-
},
|
|
58
|
-
"signage":{
|
|
59
|
-
"list":[
|
|
60
|
-
"ID Project Type Description",
|
|
61
|
-
"-------------------------- --------------- ----------------------------------------------",
|
|
62
|
-
"backlight-scheduling Web App (default) SCAP - Backlight Scheduling",
|
|
63
|
-
"app-update-without-restart Web App SCAP - App update without restart",
|
|
64
|
-
"download-progress Web App SCAP - Download progress",
|
|
65
|
-
"simple-network-failover Web App SCAP - Simple Network Failover",
|
|
66
|
-
"file-explorer Web App SCAP - File Explorer",
|
|
67
|
-
"local-content-scheduling Web App SCAP - Local Content Scheduling",
|
|
68
|
-
"timezone-setting Web App SCAP - Timezone Setting",
|
|
69
|
-
"fashion-multimedia-ad Web App Web - (Fashion/Jewelry) Fashion Multimedia",
|
|
70
|
-
"information-kiosk Web App Web - (Fashion/Jewelry) Information Kiosk",
|
|
71
|
-
"weather-dependent-ad Web App Web - (Fashion/Jewelry) Weather Dependent Adv.",
|
|
72
|
-
"flight-schedule Web App Web - (Flight Info Display) Flight Schedule",
|
|
73
|
-
"information-board Web App Web - (Public Place/Edu) Information Board",
|
|
74
|
-
"multimedia-ad Web App Web - (Public Place/Edu) Multimedia Adv.",
|
|
75
|
-
"wayfinder Web App Web - (Public Place/Edu) Wayfinder",
|
|
76
|
-
"widget-overlay Web App Web - (Public Place/Edu) Widget Overlay",
|
|
77
|
-
"mart Web App Web - (QSR/Retail) Mart",
|
|
78
|
-
"price-board-for-QSR Web App Web - (QSR/Retail) Price Board for QSR",
|
|
79
|
-
"special-menu-board Web App Web - (QSR/Retail) Special Menu Board",
|
|
80
|
-
"hello-service JS Service js service for webOS Signage",
|
|
81
|
-
"webappinfo Web App Info appinfo.json for web app",
|
|
82
|
-
"jsserviceinfo JS Service Info services.json, package.json for JS service",
|
|
83
|
-
"signageicon Icon signage app icon path [80x80, 130x130]"
|
|
84
|
-
],
|
|
85
|
-
"template": {
|
|
86
|
-
"webapp": "backlight-scheduling",
|
|
87
|
-
"jsservice": "hello-service",
|
|
88
|
-
"webappinfo": ["appinfo.json"]
|
|
89
|
-
}
|
|
90
57
|
}
|
|
91
|
-
}
|
|
58
|
+
}
|
|
Binary file
|