@lvce-editor/shared-process 0.33.5 → 0.33.6
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lvce-editor/shared-process",
|
|
3
|
-
"version": "0.33.
|
|
3
|
+
"version": "0.33.6",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"keywords": [
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"@lvce-editor/assert": "^1.3.0",
|
|
21
|
-
"@lvce-editor/extension-host-helper-process": "0.33.
|
|
21
|
+
"@lvce-editor/extension-host-helper-process": "0.33.6",
|
|
22
22
|
"@lvce-editor/ipc": "^10.2.1",
|
|
23
23
|
"@lvce-editor/json-rpc": "^3.0.0",
|
|
24
24
|
"@lvce-editor/jsonc-parser": "^1.4.0",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"@lvce-editor/typescript-compile-process": "^1.2.0",
|
|
36
36
|
"@lvce-editor/pty-host": "^2.0.0",
|
|
37
37
|
"@lvce-editor/embeds-process": "^1.5.0",
|
|
38
|
-
"@lvce-editor/preview-process": "^2.
|
|
38
|
+
"@lvce-editor/preview-process": "^2.10.0",
|
|
39
39
|
"open": "^10.1.0",
|
|
40
40
|
"tail": "^2.2.6",
|
|
41
41
|
"tmp-promise": "^3.0.3",
|
|
@@ -101,6 +101,16 @@ const applyOverrides = async ({ root, commitHash, pathPrefix }) => {
|
|
|
101
101
|
}
|
|
102
102
|
return languages;
|
|
103
103
|
};
|
|
104
|
+
const getWebViews = (extension) => {
|
|
105
|
+
const webViews = [];
|
|
106
|
+
for (const webView of extension.webViews || []) {
|
|
107
|
+
webViews.push({
|
|
108
|
+
...webView,
|
|
109
|
+
path: `${pathPrefix}/${commitHash}/extensions/${webView.path}`,
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
return webViews;
|
|
113
|
+
};
|
|
104
114
|
/**
|
|
105
115
|
* @param {string} dirent
|
|
106
116
|
*/
|
|
@@ -111,6 +121,8 @@ const applyOverrides = async ({ root, commitHash, pathPrefix }) => {
|
|
|
111
121
|
const manifests = await Promise.all(manifestPaths.map(readExtensionManifest));
|
|
112
122
|
const languages = manifests.flatMap(getLanguages);
|
|
113
123
|
await JsonFile.writeJson(Path.join(root, 'dist', commitHash, 'config', 'languages.json'), languages);
|
|
124
|
+
const webViews = manifests.flatMap(getWebViews);
|
|
125
|
+
await JsonFile.writeJson(Path.join(root, 'dist', commitHash, 'config', 'webViews.json'), webViews);
|
|
114
126
|
for (const languageBasicsDirent of languageBasicsDirents) {
|
|
115
127
|
await FileSystem.copy(Path.join(root, 'node_modules', '@lvce-editor', 'server', 'static', commitHash, 'extensions', languageBasicsDirent), Path.join(root, 'dist', commitHash, 'extensions', languageBasicsDirent));
|
|
116
128
|
}
|
|
@@ -2,6 +2,7 @@ import * as HandleIpc from '../HandleIpc/HandleIpc.js';
|
|
|
2
2
|
import * as IpcParent from '../IpcParent/IpcParent.js';
|
|
3
3
|
import * as IpcParentType from '../IpcParentType/IpcParentType.js';
|
|
4
4
|
import * as IsElectron from '../IsElectron/IsElectron.js';
|
|
5
|
+
import * as Preferences from '../Preferences/Preferences.js';
|
|
5
6
|
import * as PreviewProcessPath from '../PreviewProcessPath/PreviewProcessPath.js';
|
|
6
7
|
const getMethod = (isElectron) => {
|
|
7
8
|
if (isElectron) {
|
|
@@ -10,10 +11,13 @@ const getMethod = (isElectron) => {
|
|
|
10
11
|
return IpcParentType.NodeForkedProcess;
|
|
11
12
|
};
|
|
12
13
|
export const launchPreviewProcess = async () => {
|
|
14
|
+
const preferences = await Preferences.getUserPreferences();
|
|
15
|
+
const customPreviewProcessPath = preferences['develop.previewProcessPath'];
|
|
16
|
+
const previewProcessPath = customPreviewProcessPath || PreviewProcessPath.previewProcessPath;
|
|
13
17
|
const method = getMethod(IsElectron.isElectron);
|
|
14
18
|
const previewProcess = await IpcParent.create({
|
|
15
19
|
method,
|
|
16
|
-
path:
|
|
20
|
+
path: previewProcessPath,
|
|
17
21
|
argv: [],
|
|
18
22
|
stdio: 'inherit',
|
|
19
23
|
name: 'Preview Process',
|
|
@@ -41,9 +41,9 @@ export const getAppImageName = () => {
|
|
|
41
41
|
export const getSetupName = () => {
|
|
42
42
|
return 'Lvce-Setup';
|
|
43
43
|
};
|
|
44
|
-
export const version = '0.33.
|
|
45
|
-
export const commit = '
|
|
46
|
-
export const date = '2024-09-
|
|
44
|
+
export const version = '0.33.6';
|
|
45
|
+
export const commit = '0fe4838';
|
|
46
|
+
export const date = '2024-09-01T17:57:05.000Z';
|
|
47
47
|
export const getVersion = () => {
|
|
48
48
|
return version;
|
|
49
49
|
};
|