@24i/smartapps-bigscreen-rnv-build-engine 0.12.1-alpha.1715 → 0.12.1-alpha.1719

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.
@@ -30,7 +30,7 @@ const getHostedAppEntryUrl = (c) => {
30
30
  const deployLocations = (0, resolvers_1.resolveDeployLocations)(c);
31
31
  const keys = Object.keys(deployLocations.versions);
32
32
  let url = '';
33
- if (keys !== null && keys.length > 0) {
33
+ if (keys.length > 0) {
34
34
  const version = keys[0];
35
35
  if (version !== null) {
36
36
  const flavour = c.runtime.appId;
@@ -68,8 +68,13 @@ const createVSSolution = async (c, outputPath, manifest) => {
68
68
  const platform = new manifoldjs_windows10_1.Platform('package', ['windows10']);
69
69
  await platform.create(manifest, outputPath, ['windows10'], '');
70
70
  }
71
- catch {
72
- throw new Error('Failed to create VSSolution');
71
+ catch (e) {
72
+ if (e instanceof Error) {
73
+ if (!e.message.includes('Error retrieving information for module')) {
74
+ console.error(e.message);
75
+ throw new Error('Failed to create VSSolution');
76
+ }
77
+ }
73
78
  }
74
79
  };
75
80
  const createHostedApplication = async (c) => {
@@ -108,14 +113,19 @@ const replacePublisherId = async (c, basePath) => {
108
113
  if (identityName !== null
109
114
  && identityPublisher !== null
110
115
  && publisherDisplayName !== null) {
111
- appxmanifest = appxmanifest.replace(identityNamePlaceholder, identityName.toString())
112
- .replace(identityPublisherPlaceholder, identityPublisher.toString())
113
- .replace(publisherDisplayNamePlaceholder, publisherDisplayName.toString());
116
+ appxmanifest = appxmanifest.replace(identityNamePlaceholder, identityName)
117
+ .replace(identityPublisherPlaceholder, identityPublisher)
118
+ .replace(publisherDisplayNamePlaceholder, publisherDisplayName);
119
+ }
120
+ else {
121
+ throw new Error('failed to obtain store settings');
114
122
  }
115
123
  await fs.writeFile(output, appxmanifest ?? '');
116
124
  }
117
- catch {
118
- throw new Error('Failed to modify the xbox appxmanifest.xml');
125
+ catch (e) {
126
+ if (e instanceof Error) {
127
+ throw new Error(`Failed to modify the xbox appxmanifest.xml - ${e.message}`);
128
+ }
119
129
  }
120
130
  };
121
131
  const replaceImages = async (c) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@24i/smartapps-bigscreen-rnv-build-engine",
3
- "version": "0.12.1-alpha.1715+d8563182",
3
+ "version": "0.12.1-alpha.1719+2707dd7b",
4
4
  "description": "Package with build engine for SmartApps BIGscreen projects...",
5
5
  "main": "dist/src/index.js",
6
6
  "scripts": {
@@ -78,5 +78,5 @@
78
78
  "keywords": [],
79
79
  "author": "24i",
80
80
  "license": "ISC",
81
- "gitHead": "d8563182f72d8182a1d1dd1d8bdb8ab605b39418"
81
+ "gitHead": "2707dd7b3fd83ead21fd68f5457d0fba7661779f"
82
82
  }
@@ -1,62 +0,0 @@
1
- /* eslint-disable */
2
-
3
- const fs = require('fs').promises;
4
- const path = require('path');
5
-
6
- const main = async (resolutions) => {
7
-
8
- if (resolutions === undefined) return;
9
-
10
- const packageLockFilePath = path.resolve(__dirname, './package-lock.json');
11
-
12
- for (const [name, version] of Object.entries(resolutions)) {
13
-
14
- console.log(resolutions);
15
-
16
- const packageLock = JSON.parse(await fs.readFile(packageLockFilePath));
17
- const packagePaths = Object.keys(packageLock.packages);
18
- const deletePaths = [];
19
-
20
- for (const packagePath of packagePaths) {
21
- if (packagePath.endsWith('/' + name)) {
22
- if (packageLock.packages[packagePath].version !== version) {
23
- //deletePaths.push(packagePath);
24
- packageLock.packages[packagePath].version = version;
25
- }
26
- }
27
-
28
- if (packageLock.packages[packagePath].dependencies !== undefined) {
29
-
30
- const dependencies = packageLock.packages[packagePath].dependencies;
31
- const keys = Object.keys(dependencies);
32
- console.log(dependencies)
33
- for (const key of keys) {
34
- const dependency = dependencies[key];
35
- console.log(dependency)
36
- if (key === name) {
37
- let dependency = dependencies[key];
38
- if (dependency !== version) {
39
- delete dependencies[key];
40
- }
41
- }
42
- }
43
- }
44
- }
45
-
46
- for (const packagePath of deletePaths) {
47
- for (const deletePath of deletePaths) {
48
- if (packagePath === deletePath || packagePath.startsWith(deletePath + '/')) {
49
- // eslint-disable-next-line fp/no-delete
50
- delete packageLock.packages[packagePath];
51
- }
52
- }
53
- }
54
-
55
- await fs.writeFile(
56
- packageLockFilePath,
57
- JSON.stringify(packageLock, null, ' '),
58
- );
59
- }
60
- };
61
-
62
- main(require('../../package.json').resolutions);