@vixoniccom/module-packager 2.13.0-test.6 → 2.13.0
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/dist/webpack.config.js +4 -5
- package/package.json +3 -2
package/dist/webpack.config.js
CHANGED
|
@@ -15,19 +15,18 @@ export default (env = {}, argv = {}) => {
|
|
|
15
15
|
};
|
|
16
16
|
const isDev = options.mode === 'development' || argv.watch === true || process.env.NODE_ENV === 'development';
|
|
17
17
|
const buildPath = path.resolve(options.build);
|
|
18
|
+
const controllerHtmlPath = path.resolve(options.src, 'index.html');
|
|
19
|
+
const controllerStaticPath = path.resolve(path.dirname(controllerHtmlPath), '../static');
|
|
20
|
+
const controllerFontsPath = path.resolve(path.dirname(controllerHtmlPath), '../fonts');
|
|
21
|
+
const controllerTestPath = path.resolve(options.src, 'test');
|
|
18
22
|
// Process all environment variables
|
|
19
23
|
const getEnvironmentVariables = () => {
|
|
20
24
|
const envVars = {};
|
|
21
25
|
Object.keys(process.env).forEach((key) => {
|
|
22
26
|
envVars[`process.env.${key}`] = JSON.stringify(process.env[key]);
|
|
23
27
|
});
|
|
24
|
-
console.log('Environment variables found:', Object.keys(process.env).length);
|
|
25
28
|
return envVars;
|
|
26
29
|
};
|
|
27
|
-
const controllerHtmlPath = path.resolve(options.src, 'index.html');
|
|
28
|
-
const controllerStaticPath = path.resolve(path.dirname(controllerHtmlPath), '../static');
|
|
29
|
-
const controllerFontsPath = path.resolve(path.dirname(controllerHtmlPath), '../fonts');
|
|
30
|
-
const controllerTestPath = path.resolve(options.src, 'test');
|
|
31
30
|
return {
|
|
32
31
|
mode: isDev ? 'development' : 'production',
|
|
33
32
|
target: options.target ?? 'electron-renderer',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vixoniccom/module-packager",
|
|
3
|
-
"version": "2.13.0
|
|
3
|
+
"version": "2.13.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"bin": {
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
"scripts": {
|
|
14
14
|
"start": "electron dist/electron.js --mode run --build ./dist/build",
|
|
15
15
|
"clean": "rimraf dist",
|
|
16
|
+
"prepublish": "npm run build",
|
|
16
17
|
"build:main": "tsc -p tsconfig.json --outDir dist",
|
|
17
18
|
"build:renderer": "webpack --config webpack.config.js --env src=./ --env build=./dist/build --mode production",
|
|
18
19
|
"copy:launcher": "cpy launcher.html dist",
|
|
@@ -26,7 +27,7 @@
|
|
|
26
27
|
"@electron/remote": "^2.1.2",
|
|
27
28
|
"@types/which": "^3.0.4",
|
|
28
29
|
"@vixoniccom/module-controller": "^2.0.0",
|
|
29
|
-
"@vixoniccom/modules": "^2.
|
|
30
|
+
"@vixoniccom/modules": "^2.21.0",
|
|
30
31
|
"archiver": "^5.3.0",
|
|
31
32
|
"clean-webpack-plugin": "^4.0.0",
|
|
32
33
|
"cli-color": "^1.2.0",
|