mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-05-01 05:03:57 +00:00
try to fix electron export
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
const shell = require('./shell');
|
const shell = require('./shell');
|
||||||
const main = require('./main');
|
|
||||||
|
|
||||||
const argument = process.argv[2];
|
const argument = process.argv[2];
|
||||||
if (argument && argument.endsWith('Process')) {
|
if (argument && argument.endsWith('Process')) {
|
||||||
@@ -8,11 +7,12 @@ if (argument && argument.endsWith('Process')) {
|
|||||||
const module = proc[argument];
|
const module = proc[argument];
|
||||||
module.start();
|
module.start();
|
||||||
} else if (!module['parent'] && !process.argv.includes('--checkParent')) {
|
} else if (!module['parent'] && !process.argv.includes('--checkParent')) {
|
||||||
|
const main = require('./main');
|
||||||
|
|
||||||
main.start(argument);
|
main.start(argument);
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
...shell,
|
...shell,
|
||||||
mainModule: main,
|
getMainModule: () => require('./main'),
|
||||||
};
|
};
|
||||||
|
|||||||
2
packages/dbgate/bin/dbgate.js
Normal file → Executable file
2
packages/dbgate/bin/dbgate.js
Normal file → Executable file
@@ -2,4 +2,4 @@
|
|||||||
|
|
||||||
const dbgateApi = require('dbgate-api');
|
const dbgateApi = require('dbgate-api');
|
||||||
|
|
||||||
dbgateApi.mainModule.start('startNodeWeb');
|
dbgateApi.getMainModule().start('startNodeWeb');
|
||||||
|
|||||||
Reference in New Issue
Block a user